#11602: install_scripts should use "$@" instead of $*
----------------------+-----------------------------------------------------
Reporter: Stefan | Owner: jason
Type: defect | Status: needs_review
Priority: minor | Milestone: sage-4.7.2
Component: misc | Keywords: install_scripts, hg, command line
Work_issues: | Upstream: N/A
Reviewer: | Author:
Merged: | Dependencies:
----------------------+-----------------------------------------------------
Comment(by leif):
Replying to [comment:13 jhpalmieri]:
> > * `command` is a '''shell built-in''', and hence not an executable to
be found along `PATH`, so we need `shell=True` and a single string
containing `command -v ...` rather than a list of arguments.
>
> On OS X, it works with `shell=False`. I see now that on linux, it
doesn't.
There can be a real command `command` of course, but POSIX only requires
the shell built-in.
[[BR]]
> > * Removing `$SAGE_ROOT/local/bin` from `PATH` should IMHO be more
robust w.r.t. redundant slashs and `normpath()` or `realpath()`.
>
> [...] (In this case, anyway, the relevant portion of the PATH variable
is set by sage-env, which uses the value of SAGE_ROOT, so
"SAGE_ROOT/local/bin" should be there as is. This seems to be the case on
several different machines in which my Sage install is buried under
various symbolic links.)
I wouldn't rely on `sage-env`, not just because `SAGE_ROOT` might already
be set.
I'd rather search `PATH` for `*/local/bin*` entries and compare
`realpath()` of them to `realpath(os.path.join(SAGE_ROOT, 'local',
'bin'))`.
(Haven't yet looked at the new patch though.)
[[BR]]
Replying to [comment:14 jhpalmieri]:
> Ah, found it.
{{{
#!python
> >>> import os
> >>> os.pathsep
> ':'
}}}
Yep. On M$ Windows, it is "`;`".
--
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/11602#comment:15>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica,
and MATLAB
--
You received this message because you are subscribed to the Google Groups
"sage-trac" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/sage-trac?hl=en.