Skip to Content.
Sympa Menu

sm-commit - [SM-Commit] BZR Change 32 to devel sorcery by Andrew Stitt <astitt@sourcemage.org>

sm-commit AT lists.ibiblio.org

Subject: Source Mage code commit list

List archive

Chronological Thread  
  • From: scm AT mail.sourcemage.org
  • To: sm-commit AT lists.ibiblio.org
  • Subject: [SM-Commit] BZR Change 32 to devel sorcery by Andrew Stitt <astitt AT sourcemage.org>
  • Date: Tue, 9 May 2006 23:50:05 -0500

------------------------------------------------------------
revno: 32
committer: Andrew Stitt <astitt AT sourcemage.org>
branch nick: devel-hack4
timestamp: Tue 2006-05-09 21:48:19 -0700
message:
add -g parameter to cast

=== modified file 'ChangeLog'
--- ChangeLog
+++ ChangeLog
@@ -1,4 +1,5 @@
2006-05-09 Andrew Stitt <astitt AT sourcemage.org>
+ * cast: add -g parameter to allow custom grimoire selection and
ordering
* cast: remove --fix and --nofix (been deprecated for several
releases)

2006-05-09 Andrew Stitt <astitt AT sourcemage.org>

=== modified file 'usr/sbin/cast'
--- usr/sbin/cast
+++ usr/sbin/cast
@@ -39,6 +39,14 @@

-c | --compile Recompile the spells (dont install from
cache).
-r | --reconfigure Select new dependencies for spells (implies
-c)
+
+-g | --grimoire [...] Use only the specified grimoires for this
cast
+ NOTE: If there are any cross-grimoire
+ dependencies on unspecified grimoires they
+ will not work. The target spell will
+ not be found. To avoid this, specify all
+ relevant grimoires to the -g parameter
+ in the order you wish them to be searched.

-R | --recast-down Recast depended-upon spells, even if they are
already installed...
@@ -99,6 +107,7 @@
--no-opts) export NO_OPTIMIZATION_FLAGS=1; COMPILE="-c"; shift 1
;;
-V) export VOYEUR_OVERRIDE="$2"; shift 2
;;
--deps) export DEPS_ONLY="$1"; shift 1
;;
+ -g|--grimoire*) export OVERRIDE_GRIMOIRES="$2"; shift 2
;;
-r|--reconfigure) RECONFIGURE="$1"; COMPILE="-c"; shift 1
;;
-R|--recast-down) RECAST_DOWN="$1"; shift 1
;;
-B|--recast-up) RECAST_UP="$1"; shift 1
;;
@@ -179,6 +188,7 @@
--ldflags) shift 2 ;;
--no-opts) shift 1 ;;
-V) shift 2 ;;
+ -g|--grimoire*) shift 2 ;;
-R|--recast-down) shift 1 ;;
-B|--recast-up) shift 1 ;;
-O|--recast-optional) get_option "$2" "" x n ; shift $n ;;
@@ -783,6 +793,10 @@
process_parameters "$@"
SPELLS=`strip_parameters "$@"`

+ if [[ $OVERRIDE_GRIMOIRES ]] ; then
+ codex_set_grimoires $OVERRIDE_GRIMOIRES
+ fi
+
for spell in $SPELLS ; do
codex_does_spell_exist $spell
if [ $? -eq 0 ] ; then

=== modified file 'usr/share/man/man8/cast.8'
--- usr/share/man/man8/cast.8
+++ usr/share/man/man8/cast.8
@@ -46,6 +46,9 @@
and configuration options, even those you answered before.
Implies
.IR "-c" .
+.SS "-g, --grimoire [grimoire names ...]"
+Use only the specified grimoires for this cast.
+NOTE: If there are any cross-grimoire dependencies on unspecified grimoires
they will not work. The target spell will not be found. To avoid this,
specify all relevant grimoires to the -g parameter in the order you wish them
to be searched.
.SS "--from directory"
Specify an alternate directory to search for cached sources.
An alternate to /var/spool/sorcery.

=== modified file 'var/lib/sorcery/modules/libdepends'
--- var/lib/sorcery/modules/libdepends
+++ var/lib/sorcery/modules/libdepends
@@ -643,7 +643,7 @@
fi

# see if theres another grimoire
- if [[ "$4" ]] ; then
+ if [[ "$4" ]] && ! [[ "$OVERRIDE_GRIMOIRES" ]] ; then
local grimoire here nothere current

for grimoire in $4; do
@@ -772,7 +772,7 @@
fi

# see if theres another grimoire
- if [[ "$5" ]] ; then
+ if [[ "$5" ]] && ! [[ "$OVERRIDE_GRIMOIRES" ]] ; then
local grimoire here nothere current
for grimoire in $5; do
if [[ "$grimoire" == "current" ]] ; then




  • [SM-Commit] BZR Change 32 to devel sorcery by Andrew Stitt <astitt AT sourcemage.org>, scm, 05/10/2006

Archive powered by MHonArc 2.6.24.

Top of Page