#8679: conventions for spkg names, rewriting sage-spkg
-----------------------------+----------------------------------------------
   Reporter:  jhpalmieri     |       Owner:  tbd     
       Type:  enhancement    |      Status:  new     
   Priority:  major          |   Milestone:  sage-4.4
  Component:  packages       |    Keywords:          
     Author:  John Palmieri  |    Upstream:  N/A     
   Reviewer:                 |      Merged:          
Work_issues:                 |  
-----------------------------+----------------------------------------------
 Some scripts in SAGE_ROOT/local/bin expect spkg names to have the form
 {{{
 my_package-2.3.spkg
 }}}
 but not
 {{{
 my-package-2.3.spkg   (first hyphen is bad)
 }}}
 See [http://groups.google.com/group/sage-
 devel/browse_thread/thread/8597ce93b420afe4 sage-devel] for some
 discussion.

 The attached patches do three things:

  - Rewrite sage-pkg (in python instead of bash) to test whether the name
 has the right form.
  - Remove sage-pkg-nocompress, using sage-pkg instead (and thus unifying
 the two scripts sage-pkg and sage-pkg-nocompress).
  - Add some comments about this to the developer's guide (hence the cc for
 mvngu).

 I used python because in the old version of sage-pkg, we were already
 calling sed and perl, and we might need to call perl again (or something
 else?) to test whether the name has the right form.  It seems easier to
 maintain if it's all plain Python.

 Here is the standard being suggested by this patch: each Sage spkg should
 have a name of the following form:
 {{{
 BASENAME-VERSION.spkg
 }}}
 where BASENAME may lowercase letters, numbers, and underscores, but '''no
 hyphens'''.  VERSION '''must be present''' and '''should start with a
 number'''; it may contain numbers, letters, dots, and hyphens; it may end
 in a string of the form "pNUM", where "NUM" is a non-negative integer.
 The new version of sage-pkg sets BASENAME to be everything up to the first
 hyphen, but it does not check to make sure only numbers, lowercase
 letters, and underscores are used.  It checks that VERSION is present,
 starts with a number, and contains only numbers, letters, periods,
 hyphens.  If not, it prints a warning and creates an spkg anyway.

 I've tried to implement the change at #2522, but I'm not sure how to test
 it.  Any suggestions?  What sort of "OS X junk" should I try to put in my
 directory, to make sure it is not put into the resulting spkg file?

-- 
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/8679>
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.

Reply via email to