Marcus Smith
49bc592bf2
add list command to registry
2012-12-15 20:23:55 -08:00
Rafael Caricio
c862877ccf
Change tests to use mock instead of pytz.
2012-12-15 19:42:29 -08:00
Rafael Caricio
be1083a06c
Some fixes after @carljim review.
2012-12-15 19:42:29 -08:00
Rafael Caricio
29972a1b3a
Add the --uptodate flag in the list command.
2012-12-15 19:42:28 -08:00
Rafael Caricio
5a02b6674e
Basic behaviour of the list command.
2012-12-15 19:42:28 -08:00
Rafael Caricio
0267e8a684
Modifies the outdated command to list command.
2012-12-15 19:42:28 -08:00
Rafael Caricio
ff24b578ba
Make the test pass.
2012-12-15 19:42:28 -08:00
Rafael Caricio
8682dfe644
Remove blank spaces.
2012-12-15 19:42:28 -08:00
Miguel Araujo Perez
873d3bc34c
Checking requirements before adding them to installations
2012-12-15 19:42:28 -08:00
Miguel Araujo Perez
8111bbb550
Updating pip outdated to use PackageFinder
instead. Adding extra options like '--index-url' or '--find-links'. Changing version comparison to use > not !=
...
All work done here is based on @carljm suggestions made in pull request #235 , so that pip outdated gets merged into master asap.
2012-12-15 19:42:28 -08:00
Dmitry Gladkov
91106054ca
add outdated pip command
2012-12-15 19:42:28 -08:00
Georgi Valkov
b26cdee1e6
move command options before general options
...
Add a new base parser class 'CustomOptionParser' that provides the
'insert_option_group(idx, *, **)' method for inserting an option group
at a specific position.
2012-12-12 15:06:05 +02:00
Georgi Valkov
416ab39519
'Command Options' for the show command
2012-12-10 03:30:17 +02:00
Georgi Valkov
8b1836b401
'Command Options' for the uninstall command
2012-12-10 03:30:17 +02:00
Georgi Valkov
8f00079a4b
'Command Options' for the zip command
2012-12-10 03:30:17 +02:00
Georgi Valkov
6d8b55a39b
'Command Options' for the search command
2012-12-10 03:30:12 +02:00
Georgi Valkov
192f1552bc
'Command Options' for the freeze command
2012-12-10 03:24:48 +02:00
Georgi Valkov
b34feacbf9
add the Command.gen_opts option group
...
Note that commands still have to add the option group to the parser
once they populate it with options (self.parser.add_option_group).
2012-12-10 03:22:28 +02:00
Georgi Valkov
2c09666c31
split install options into 'Command Options' and 'Package Index Options'
2012-12-10 03:14:39 +02:00
Georgi Valkov
715c7eff71
fix error output
...
`pip help <misspelled>` should return the same error message as `pip
<misspelled>`, namely:
ERROR: unknown command "enstall" - maybe you meant "install"
2012-12-06 17:25:40 +02:00
Georgi Valkov
e103e549d7
fix bare except statement
2012-12-06 17:25:28 +02:00
Georgi Valkov
7f4503b9e2
pep8 fixes
2012-12-06 17:25:19 +02:00
Marcus Smith
53bbdf58cd
merge with pypa/pip:develop
2012-11-28 20:28:57 -08:00
Marcus Smith
9c271baafe
distutils scheme util for wheel installs; --user/--target support for wheels
2012-11-14 16:53:22 -08:00
Georgi Valkov
2c64a1e160
replace global OptionParser and refactor main()
2012-11-10 15:37:15 +02:00
Georgi Valkov
46a21751b8
add the base_parser argument to all Command instances
2012-11-10 15:34:53 +02:00
Georgi Valkov
7427eca00b
remove global command instances
...
Rework the way commands are defined, loaded and ran in pip:
- Commands are instantiated on demand in pip.main().
- A command 'registry' - mapping of command names to command classes in
pip.commands.__init__.
- Remove deferred command module loading.
2012-11-10 15:30:16 +02:00
Marcus Smith
7ece6f4e77
add --no-deps option to "pip wheel"
2012-10-27 21:21:35 -07:00
Daniel Holth
ed0c2391da
allow pip wheel --use-wheel ...
2012-10-27 16:55:04 -04:00
Daniel Holth
137909107f
remove 'import *'
2012-10-27 16:29:31 -04:00
Daniel Holth
e0f353596f
make sure bdist_wheel is available up front
2012-10-16 21:57:37 -04:00
Marcus Smith
a0cd7b6991
use CommandError
2012-10-16 16:48:15 -07:00
Marcus Smith
cdcdf459bc
'pip wheel' doesn't support py25
2012-10-16 16:39:56 -07:00
Marcus Smith
4bfc92ddba
'pip wheel'
2012-10-16 15:57:10 -07:00
hetmankp
061954f29d
Added --root command line option, works the same as for distutils
2012-10-08 14:49:30 +11:00
Daniel Holth
aa5b33dbf4
experimental support for installing wheel archives
2012-10-01 22:50:24 -07:00
Carl Meyer
28aeb03b08
Add dependencies information to 'show' command.
2012-09-21 11:15:24 -06:00
Carl Meyer
8c9a241fb2
Rename 'status' command 'show'.
2012-09-12 10:39:19 -06:00
Rafael Caricio
85bbe26f64
Make optional the full file listing.
2012-09-11 17:44:42 -03:00
Rafael Caricio
71286afc4d
Enable listing all the installed files.
2012-09-11 16:35:03 -03:00
Carl Meyer
6d5a9e2fb2
Minor cleanup.
2012-09-08 15:31:59 -06:00
Rafael Caricio
63459a2707
Little refactory.
2012-09-07 18:18:48 -04:00
Rafael Caricio
16f76e24bd
Only print some files.
2012-09-07 17:44:49 -04:00
Rafael Caricio
b78dff8d2c
Refactory and support to package name in any case.
2012-09-07 17:17:04 -04:00
Rafael Caricio
76bbecd42e
Added the patch code sent by @vbabiy.
2012-09-07 15:56:00 -04:00
Jannis Leidel
1525a63b57
Added a get_prog util to correctly show the name of the program when using python -m pip.
...
Also show the full path in the missing command error message.
2012-09-01 20:36:31 +02:00
MiCHiLU
4d955d56af
Fix issue #632 - IOError in zip command with --path option
2012-08-13 13:02:16 +09:00
Marcus Smith
5a1c6093b6
pypy home scheme fix
2012-08-04 18:48:16 -07:00
Marcus Smith
0aadda7f16
usersite installs should ignore version conflicts with site
2012-06-10 18:16:48 -07:00
Marcus Smith
2e1959abfb
don't allow --user installs in no-global virtualenvs
2012-06-05 20:01:35 -07:00
Kamal Bin Mustafa
93cd6b1620
add --egg option to opt out --single-version-externally-managed
2012-05-20 11:18:36 +08:00
Paul Nasrat
2606cf37a6
Issue #482 search raises exception.
...
Handle pypi results for packages with no ordering.
TESTED=2.4.6 2.7.1 3.2.2
2012-03-18 10:33:13 +00:00
Stavros Korokithakis
d8babe79f2
--target-dir implies --ignore-installed.
2012-02-07 09:13:02 +02:00
Carl Meyer
ec5d336254
Fix shutil.move and test.
2012-02-03 12:37:53 -07:00
Stavros Korokithakis
eb03ec0dc1
Remove temporary directory, reduce option parameters.
2012-02-03 13:22:51 +02:00
Stavros Korokithakis
176d3a2663
Add target directory option.
2012-02-03 05:23:07 +02:00
Qiangning Hong
fa773cdec6
clean up temporary source code
2012-02-01 14:25:06 +08:00
Hugo Lopes Tavares
a3c42a3bcc
Fix issue #22 - pip search should set and return a userful shell status code
2011-12-29 16:25:46 -02:00
Hugo Lopes Tavares
6686e4df25
Merge branch develop from pypa/pip into hugobr/issue-22-search-should-set-useful-status-code
2011-12-04 18:58:33 -02:00
Hugo Lopes Tavares
615e724de2
Move status codes to a module and import from there
2011-12-04 18:50:34 -02:00
Herbert Pfennig
9732a96680
Fixes #391 : "pip freeze -r" ValueError if requirements file contains --find-links or --index-url
2011-12-03 21:59:16 -08:00
Carl Meyer
cfc1237360
Handle option defaults better in bundle command; fixes failing test introduced in pull request #340 .
2011-10-24 10:50:56 -06:00
Carl Meyer
9f547d0e3d
Merge pull request #340 from iguananaut/fix-install-defaults
...
Display correct defaults for pip install --help
2011-10-22 23:03:21 -07:00
Carl Meyer
cdec82b5e6
Merge branch 'fix-issue-49' into develop
2011-10-22 23:50:19 -06:00
Craig Kerstiens
b99427d94e
Allowing empty requirements.txt to be specified as valid dependency list by stopping to raise an InstallationError if the requirements set is empty. Closes #345 .
2011-09-13 16:25:20 +02:00
Erik Bray
1ecda0db16
Fix --upgrade to leave already up-to-date packages alone. Add --force-reinstall to force reinstallation even of up-to-date packages, as was the prior behavior.
2011-08-24 14:07:16 -04:00
Erik Bray
981b0f8a4c
Display correct defaults (incorporating defaults from pip.conf) for src_dir and build_dir in pip install --help output
2011-08-22 13:38:46 -04:00
Paul Nasrat
2a5e21b41f
Merge remote branch 'pnasrat/260-py3k-comparison-issue' into develop
2011-08-14 14:45:36 +01:00
Paul Nasrat
09bba5b4aa
Fix pep8
2011-08-04 16:09:38 +01:00
Hugo Lopes Tavares
9575e62b93
Moved SUCCESS and ERROR to basecommand.py, and added a FIXME, explaining why there is a integer check for status (return from self.run)
2011-08-02 13:54:18 -04:00
Hugo Lopes Tavares
7989ea9c5b
Changed HelpCommand to raise CommandError instead of InstalationError, when no command is found. It returns status SUCCESS (0) if find command or no command is specified.
2011-08-02 13:41:31 -04:00
Hugo Lopes Tavares
8e8ef0e34a
Changed SearchCommand.run to return SUCCESS or NO_MATCHES_FOUND (0 and 23) for found packages, and not found packages. Changed BaseCommand to check if run
returned int, and if so, it is the exit status code [dummy change, just to no break everything right now; the other commands should be changed too!]. Removed SearchCommandError because it was not used
2011-08-02 13:16:18 -04:00
Alex Morega
a58839e194
"search" command reports error via exception
2011-07-20 22:14:56 +03:00
Paul Nasrat
2860dc7d41
Fix whitespace, etc for pep8 compliance
...
Reran tests after changes on 2.4, 2.6, 3.2 all pass.
=====================================================
================== Running pep8 =====================
Searching for pep8
Reading http://pypi.python.org/simple/pep8/
Reading http://github.com/cburroughs/pep8.py/tree/master
Reading http://github.com/jcrocholl/pep8
Best match: pep8 0.6.1
Processing pep8-0.6.1-py2.6.egg
pep8 0.6.1 is already the active version in easy-install.pth
Installing pep8 script to /Users/pnasrat/Development/pip/pip_virtualenv/bin
Using /Users/pnasrat/Development/pip/pip_virtualenv/lib/python2.6/site-packages/pep8-0.6.1-py2.6.egg
Processing dependencies for pep8
Finished processing dependencies for pep8
==================== Ended pep8 =====================
=====================================================
2011-05-04 08:44:02 +01:00
Paul Nasrat
0922f81352
Work around failing test due to distutils.version issue
...
In py3k the following fails, handle this and use string comparison in worst
case.
Tested on 2.6 and 3.2
>> from distutils.version import LooseVersion as LV
>>> v1, v2, v3 = (LV('1.1'), LV('1.1.2'), LV('1.1a1'))
>>> v1 > v2
False
>>> v1 > v3
False
>>> v2 > v3
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "distutils/version.py", line 70, in __gt__
c = self._cmp(other)
File "distutils/version.py", line 343, in _cmp
if self.version < other.version:
TypeError: unorderable types: int() < str()
2011-04-16 22:01:05 +01:00
Paul Nasrat
1691ee3855
Use pypi query list to support multiple cli searches Issue #44
2011-04-17 01:02:57 +08:00
Vinay Sajip
680b5dfda0
Port to Python3
2011-03-15 15:49:48 -04:00
Jannis Leidel
4d98a308ec
Completely use our rmtree instead of shutil.rmtree direct.
2010-11-22 20:32:14 +01:00
Jannis Leidel
d921b1dc55
Also bail in the uninstall command, if no requirement is given.
2010-08-31 14:51:15 +02:00
Jannis Leidel
2f44bcd392
Fixed issue #151 -- When running the install command, bail early if no requirement is given.
2010-08-31 03:01:03 +02:00
Carl Meyer
2249c100b1
nicer error for --user on pre-2.6 Pythons
2010-08-19 12:59:10 -04:00
Carl Meyer
285ff9eed6
fix missing InstallationError import
2010-08-19 12:58:48 -04:00
Ronny Pfannschmidt
8606eaff95
implement and test early error-out on setuptools for install --user --editable
2010-08-19 17:40:21 +02:00
Ronny Pfannschmidt
1e76e5abcc
merge "--user alias" to main
2010-08-19 16:24:34 +02:00
Ronny Pfannschmidt
2103c4ffcd
add a --user alias for --install-opt=--user
2010-08-18 23:59:33 +02:00
Hugo Lopes Tavares
0ccd5ebf97
using custom xmlrpclib.Transport (testability purposes)
2010-07-02 09:27:22 -03:00
Jannis Leidel
e80c387a26
Added support for mirrors as defined in PEP 381. This feature is disabled by default and will query the DNS entry of the main mirror index URL to get a list of mirrors. Optinally can be passed a list of mirrors instead.
2010-08-16 01:46:23 +02:00
Carl Meyer
eff68029e3
merge installcommand/finder subclass hooks
2010-06-04 11:20:35 -04:00
Hugo Lopes Tavares
26a1314d1d
some adapts to pep8
2010-06-03 17:40:45 -03:00
Ronny Pfannschmidt
d8b00e253b
add support for global distutils options
2010-05-30 14:39:11 +02:00
Hugo Lopes Tavares
d06c98dc6f
merged changes related to PEP 8 from hltbra's fork
2010-06-02 23:25:26 -03:00
Dave Abrahams
6c68932526
Hooks for ryppl. The following are now encapsulated in overridable methods:
...
1. Construction of the install command's package finder
2. Derivation of available versions from links
2010-05-27 19:27:13 -04:00
Dave Abrahams
4b2eedc50a
On Windows, .pth files must be saved in binary mode ('wb')
...
...because they are written by easy_install with Unix line
endings (\n) there and if we write DOS line endings (\r\n) as 'w'
does, our uninstall tests that check for complete rollback of
easy-install.pth fail.
2010-05-02 22:18:41 -04:00
Dave Abrahams
b32d6f4798
Use portable path manipulations for Windows portability
2010-04-24 03:06:42 -04:00
Alexandre Conrad
aaccedf26a
centralized clean up code in one place
2010-04-17 18:36:31 +02:00
Alexandre Conrad
627c3e7242
Remove build directories after commands. Fixes #57
2010-04-16 19:26:39 +02:00
Hugo Lopes Tavares
660253c20f
changed error to go to stderr
2010-04-15 19:19:31 -03:00
Hugo Lopes Tavares
8aa964194c
removed unused code
2010-04-15 16:09:01 -03:00
Carl Meyer
85fae257c2
Fix some pyflakes warnings. Thanks Simon Cross.
2010-04-15 11:59:55 -04:00
Simon Cross
baa49969fd
Add search for source folders if not downloading files (--no-download tests should now pass).
2010-04-15 15:27:00 +02:00
Simon Cross
4fba7f2f55
Add option to not download anything (and just use what was downloaded earlier.).
2010-04-15 14:03:36 +02:00
Simon Cross
83c099d8c9
Always make build_dir and src_dir absolute (fixes failing download with relative src folder test).
2010-04-15 13:16:11 +02:00
Carl Meyer
d793133780
support Debian/Ubuntu "dist-packages" in zip command. Thanks duckx. Fixes #80
2010-04-13 16:08:54 -04:00
Carl Meyer
96bb90d434
move logging setup earlier in main() to avoid raw prints; fixes #75
2010-03-09 16:31:03 -05:00
Carl Meyer
107835ec99
factor out get_installed_distributions utility function and add pip uninstall autocomplete; fixes #76
2010-03-09 14:39:48 -05:00
Cody Soyland
64360ffe9b
Change function name "translate_hits" to "transform_hits" for clarity.
2010-02-23 15:01:43 -06:00
Cody Soyland
7f709ba830
Do not print separate line for latest version if it is installed.
2010-02-22 18:20:19 -05:00
Cody Soyland
02085e8858
Use logger.indent instead of printing spaces.
2010-02-22 18:10:56 -05:00
Cody Soyland
d29756822a
Join query args with space instead of choosing first word.
2010-02-22 17:45:53 -05:00
Cody Soyland
7768c7865f
Replace print statements with logging.
2010-02-22 17:43:49 -05:00
Cody Soyland
9415e28449
Fix for cases in which terminal size cannot be determined.
2010-02-22 17:37:19 -05:00
Cody Soyland
e238291990
Added pip search command with basic documentation and tests.
2010-02-22 17:03:05 -05:00
Carl Meyer
9a465eeb10
add --local option to freeze; fixes #9
2010-02-22 00:37:28 -05:00
Carl Meyer
4d8dffbdb1
preserve options from template reqs files: fixes #37
2009-12-12 17:26:28 -05:00
Ian Bicking
13a3083066
Fix for pip bundle and local files, from whit
2009-12-08 13:25:07 -06:00
Ian Bicking
8ed9acae60
Factor out the requirement handling into pip.req, and most of the remaining utility functions into pip.util
2009-11-20 18:26:59 -06:00
Ian Bicking
b0df48ad31
Factor out the PackageIndex code; move more stuff to pip.util
2009-11-20 17:39:44 -06:00
Ian Bicking
dc6b8393eb
Extracted the vcs support into a package/modules. Moved some routines from __init__ into pip.util
2009-11-20 15:03:40 -06:00
Ian Bicking
3d32c196b5
Extract commands into their own modules; fix a few imports and dead functions that pyflakes found
2009-11-20 12:20:52 -06:00