Show More
@@ -19,6 +19,10 b' From the command line:' | |||||
19 |
|
19 | |||
20 | $ python -m IPython.external.mathjax |
|
20 | $ python -m IPython.external.mathjax | |
21 |
|
21 | |||
|
22 | To a specific profile: | |||
|
23 | ||||
|
24 | $ python -m IPython.external.mathjax --profile=research | |||
|
25 | ||||
22 | To install MathJax from a file you have already downloaded: |
|
26 | To install MathJax from a file you have already downloaded: | |
23 |
|
27 | |||
24 | $ python -m IPython.external.mathjax mathjax-xxx.tar.gz |
|
28 | $ python -m IPython.external.mathjax mathjax-xxx.tar.gz | |
@@ -202,13 +206,13 b' def main() :' | |||||
202 | parser.add_argument( |
|
206 | parser.add_argument( | |
203 | '-p', |
|
207 | '-p', | |
204 | '--profile', |
|
208 | '--profile', | |
205 | help='profile to install MathJax to. Takes precedence over install-dir option') |
|
209 | default='default', | |
|
210 | help='profile to install MathJax to (default is default)') | |||
206 |
|
211 | |||
207 | parser.add_argument( |
|
212 | parser.add_argument( | |
208 | '-i', |
|
213 | '-i', | |
209 | '--install-dir', |
|
214 | '--install-dir', | |
210 | default=default_dest, |
|
215 | help='custom installation directory') | |
211 | help='installation directory (by default : %s)' % (default_dest)) |
|
|||
212 |
|
216 | |||
213 | parser.add_argument( |
|
217 | parser.add_argument( | |
214 | '-d', |
|
218 | '-d', | |
@@ -231,13 +235,13 b' def main() :' | |||||
231 |
|
235 | |||
232 | pargs = parser.parse_args() |
|
236 | pargs = parser.parse_args() | |
233 |
|
237 | |||
234 | if(pargs.profile): |
|
238 | if pargs.install_dir: | |
|
239 | # Explicit install_dir overrides profile | |||
|
240 | dest = pargs.install_dir | |||
|
241 | else: | |||
235 | profile = pargs.profile |
|
242 | profile = pargs.profile | |
236 | static = os.path.join(locate_profile(profile), 'static') |
|
243 | static = os.path.join(locate_profile(profile), 'static') | |
237 | dest = os.path.join(static, 'mathjax') |
|
244 | dest = os.path.join(static, 'mathjax') | |
238 | else: |
|
|||
239 | dest = pargs.install_dir |
|
|||
240 |
|
||||
241 |
|
245 | |||
242 | if pargs.dest : |
|
246 | if pargs.dest : | |
243 | print dest |
|
247 | print dest |
General Comments 0
You need to be logged in to leave comments.
Login now