Mercurial > hg > carton
annotate README.txt @ 40:39fa450b21bd default tip
updates for today
author | Jeff Hammel <k0scist@gmail.com> |
---|---|
date | Mon, 22 Feb 2016 14:16:09 -0800 |
parents | 261e2d2d26ad |
children |
rev | line source |
---|---|
31
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
1 carton |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
2 ====== |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
3 |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
4 make a self-extracting virtualenv from directories or URLs of packages |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
5 |
40 | 6 See the docstring of carton.py for documentation: http://k0s.org/hg/carton/file/tip/carton.py#l3 |
31
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
7 |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
8 Carton provides a one-file portable package of a virtualenv and all of |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
9 its software. |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
10 |
40 | 11 Carton lives at http://k0s.org/hg/carton |
32 | 12 |
13 Tests illustrating carton's use are at | |
14 http://k0s.org/mozilla/hg/carton/file/tip/tests/doctest.txt | |
15 | |
40 | 16 A self-extracting carton of, um, carton is at |
32 | 17 http://k0s.org/mozilla/hg/carton/file/tip/carton-env.py |
18 | |
31
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
19 |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
20 Why did you write this thing? |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
21 ----------------------------- |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
22 |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
23 For whatever reasons, people have trouble using virtualenv so I |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
24 figured I'd make that easy. People also seem to believe that you can |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
25 zip up a virtualenv and treat it as portable. In general, virtualenvs |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
26 are architecture and library dependent, so this isn't a good idea. |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
27 carton works around this problem by packaging the instructions |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
28 necessary to make the virtualenv instead of dealing with |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
29 library/hardware incompatabilities. |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
30 |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
31 |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
32 Should I use carton for my deployment strategy? |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
33 ----------------------------------------------- |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
34 |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
35 Maybe. Carton is pretty minimalist. It does effectively one thing: |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
36 makes a file that unfolds to a virtualenv with software setup for |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
37 development. If this fits in with what you want to do, then sure! If |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
38 not, then probably not. |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
39 |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
40 |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
41 TODO |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
42 ---- |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
43 |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
44 carton is essentially finished. Features can be added by request |
40 | 45 (just mail me: k0scist __at___ gm ail __dot__ com ), but the scope of |
31
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
46 the project is pretty much fulfilled. |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
47 |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
48 There are a few items I would like to add: |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
49 |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
50 - currently, carton only works if connected to a network or if a local |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
51 virtualenv tarball is specified with `--virtualenv`. I would like to |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
52 make a script, `regen_virtualenv.py`, that would add a hashed value |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
53 of the virtualenv tarball to the global `VIRTUAL_ENV` |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
54 variable. Similarly, one should be able to retrieve the stripped |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
55 down version of the script without this hash if desired |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
56 |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
57 - ... and being able to take virtualenv from its import path, if |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
58 available |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
59 |
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
60 - it would be nice to be able to specify a post-deployment script to |
40 | 61 be run |
31
8fef97a25925
near version bump and documentation
Jeff Hammel <jhammel@mozilla.com>
parents:
24
diff
changeset
|
62 |
34 | 63 |
64 Links | |
65 ----- | |
66 | |
67 Projects solving related problems: | |
68 | |
69 * https://github.com/jbalogh/vending-machine: a script for managing | |
70 vendor libraries | |
71 | |
72 * https://bitbucket.org/kumar303/eco: Eco helps you maintain a local | |
73 Python ecosystem | |
74 | |
75 * https://bitbucket.org/kumar303/velcro/: Velcro is a script that sets | |
76 up a Python project for local installation. Essentially, it | |
77 "fastens" together virtualenv and optionally pip too. | |
78 | |
79 * http://www.virtualenv.org/en/latest/index.html#creating-your-own-bootstrap-scripts |