Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

reincarnate -V cmdline option #926

Closed
wants to merge 1 commit into from

3 participants

@yarikoptic

please allow at least to check for version consistently with previous versions.
Since -V is not used by anything else, please let it stay. You could spit out
deprecation warning meanwhile to discourage its use, but it remains the only way
to check which version of ipython is actually available from the cmdline (might
be useful to scripts/mode wrappers for editors etc)

@yarikoptic yarikoptic allow for consistent version checking with previous releases of ipython
please allow at least to check for version consistently with previous versions.
Since -V is not used by anything else, please let it stay.  You could spit out
deprecation warning meanwhile to discourage its use, but it remains the only way
to check which version of ipython is actually available from the cmdline (might
be useful to scripts/mode wrappers for editors etc)
ae2a211
@minrk
Owner

Entirely sensible. Of course, as with most python packages, the following always works:

python -c "import IPython; print IPython.__version__"

Which you would have to do if you want your test to allow for 0.11, which lacks this fix.

@yarikoptic

grhm -- I feel silly now -- I should have indeed just relied on that ... feel free to 'close' without adopting/merging ;)

@minrk
Owner

No worries, I think it's still valid and tiny change. No need to have excessive incompatibility, especially for methods specifically for checking compatibility.

@fperez
Owner

+1, merge away (with rebase to avoid recursive merge for a single commit). @yarikoptic, note also that at the cmd line, --version should also work..

@minrk minrk closed this pull request from a commit
@yarikoptic yarikoptic restore '-V' cmdline option for printing version
Preserves compatibility with pre-0.11 call, which was broken unnecessarily.

closes gh-926
df951f4
@minrk minrk closed this in df951f4
@ellisonbg ellisonbg referenced this pull request from a commit
Commit has since been removed from the repository and is no longer available.
@mattvonrocketstein mattvonrocketstein referenced this pull request from a commit in mattvonrocketstein/ipython
@yarikoptic yarikoptic restore '-V' cmdline option for printing version
Preserves compatibility with pre-0.11 call, which was broken unnecessarily.

closes gh-926
42624ba
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Oct 24, 2011
  1. @yarikoptic

    allow for consistent version checking with previous releases of ipython

    yarikoptic authored
    please allow at least to check for version consistently with previous versions.
    Since -V is not used by anything else, please let it stay.  You could spit out
    deprecation warning meanwhile to discourage its use, but it remains the only way
    to check which version of ipython is actually available from the cmdline (might
    be useful to scripts/mode wrappers for editors etc)
This page is out of date. Refresh to see the latest.
Showing with 1 addition and 1 deletion.
  1. +1 −1  IPython/config/application.py
View
2  IPython/config/application.py
@@ -393,7 +393,7 @@ def parse_command_line(self, argv=None):
self.print_examples()
self.exit(0)
- if '--version' in argv:
+ if '--version' in argv or '-V' in argv:
self.print_version()
self.exit(0)
Something went wrong with that request. Please try again.