might this be useful ?

Ben Abbott bpabbott at mac.com
Sun Sep 28 17:33:53 CDT 2008


I've killed a few hour working on a bash script to help automate the  
submission of minor changesets. It is attached.

As I'm not experienced in writing such scripts there are likely bugs.

 From time to time,  there has been discussions regarding a desire to  
simplify the submission of changesets, I thought such a script might  
of interest.

I do not know if it works on Windows (cygwin), and while I don't  
expect problems with Linux, I'm only sure that it works on Mac OSX.

Any feedback is welcome ... including a critique of my bash  
scripting ;-) ... in fact, I appreciate advice on how to do a better  
job.

The help text is

$ ./octave_changeset -h

Usage: ./octave_changeset options filename

This script automates the creation of a simple changeset for Octave. A
ChangeLog entry will be included in the nearest instance of "ChangeLog"
found in the path.

The script only supports changes to a single file.

OPTIONS:
    -a <path-to-archive>		 Path to the root of the Octave archive
    -d <description of change>	 Descrition of change
    -h 				 Show this message
    -o 				 Output file for changeset
    -p <path-in-archive>		 Path to the file in the archive
    -u <user-name & email>	 User/contributer name
    -v 				 Verbose

If the "username" field in ~/.hgrc is set it will be used as the  
default.

If the path to the file in the archive is not specified, but the path to
the archive and the file name is specified, an attempt will be made to
locate the file.

If the doc-string is not specified, an inquiry is made.

In verbose mode the changeset will be written to "changeset- 
$filename.txt"

EXAMPLES:
./octave_changeset -a "~/Development/mercurial/octave" -d  
"Clarification of the doc-string" pcolor.m

export OCTAVEARCHIVE="~/Development/mercurial/octave"
./octave_changeset -d "Clarification of the doc-string" pcolor.m

export OCTAVEARCHIVE="~/Development/mercurial/octave"
$0 -d "Clarification of the doc-string" -o "changeset.txt" pcolor.m

-------------- next part --------------
An HTML attachment was scrubbed...
URL: https://www-old.cae.wisc.edu/pipermail/octave-maintainers/attachments/20080928/3388f1cf/attachment.html 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: octave_changeset
Type: application/octet-stream
Size: 7177 bytes
Desc: not available
Url : https://www-old.cae.wisc.edu/pipermail/octave-maintainers/attachments/20080928/3388f1cf/attachment.obj 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: https://www-old.cae.wisc.edu/pipermail/octave-maintainers/attachments/20080928/3388f1cf/attachment-0001.html 


More information about the Octave-maintainers mailing list