#12606: Fix sage --info <package>
----------------------------------+-----------------------------------------
Reporter: jdemeyer | Owner: leif
Type: defect | Status: closed
Priority: minor | Milestone: sage-5.4
Component: scripts | Resolution: fixed
Keywords: | Work issues:
Report Upstream: N/A | Reviewers: John Palmieri
Authors: Jeroen Demeyer | Merged in: sage-5.4.beta0
Dependencies: | Stopgaps:
----------------------------------+-----------------------------------------
Comment (by jhpalmieri):
What would you think of a patch like this:
{{{
#!diff
diff --git a/spkg/bin/sage b/spkg/bin/sage
--- a/spkg/bin/sage
+++ b/spkg/bin/sage
@@ -919,9 +919,13 @@ install() {
PKG_NAME=`echo "$PKG" | sed -e "s/\.spkg$//"`
PKG_NAME=`basename "$PKG_NAME"`
- "$SAGE_ROOT"/spkg/pipestatus \
- "sage-spkg $OPTINFO $OPTF $OPTS $OPTC '$PKG' 2>&1" \
- "(trap '' SIGINT; tee -a '$SAGE_ROOT/install.log'
'$SAGE_LOGS/$PKG_NAME.log')"
+ if [ -n $OPTINFO ]; then
+ sage-spkg "$OPTINFO" "$PKG" 2>&1
+ else
+ "$SAGE_ROOT"/spkg/pipestatus \
+ "sage-spkg $OPTINFO $OPTF $OPTS $OPTC '$PKG' 2>&1" \
+ "(trap '' SIGINT; tee -a '$SAGE_ROOT/install.log'
'$SAGE_LOGS/$PKG_NAME.log')"
+ fi
# Do not try to install further packages if one failed
if [ $? -ne 0 ]; then
exit 1
}}}
(Or we can run `sage-spkg --info "$PKG"` for two cases in the `case`
block.) Basically, I don't think that running `sage --info foo` should
produce a file `spkg/logs/foo.log`.
--
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/12606#comment:6>
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.