Skip to Content.
Sympa Menu

sm-commit - [SM-Commit] GIT changes to master grimoire by Justin Boffemmyer (bcfaa14db3fff798936d7bb32bf0beaa593fa0b5)

sm-commit AT lists.ibiblio.org

Subject: Source Mage code commit list

List archive

Chronological Thread  
  • From: Justin Boffemmyer <scm AT sourcemage.org>
  • To: sm-commit AT lists.ibiblio.org
  • Subject: [SM-Commit] GIT changes to master grimoire by Justin Boffemmyer (bcfaa14db3fff798936d7bb32bf0beaa593fa0b5)
  • Date: Thu, 3 Jun 2010 19:14:08 -0500

GIT changes to master grimoire by Justin Boffemmyer <flux AT sourcemage.org>:

ChangeLog | 3 +
smgl/cauldron/BUILD | 1
smgl/cauldron/CONFIGURE | 23 +++++++++
smgl/cauldron/DEPENDS | 17 ++++++
smgl/cauldron/DETAILS | 18 +++++++
smgl/cauldron/HISTORY | 3 +
smgl/cauldron/INSTALL | 117
++++++++++++++++++++++++++++++++++++++++++++++++
7 files changed, 182 insertions(+)

New commits:
commit bcfaa14db3fff798936d7bb32bf0beaa593fa0b5
Author: Justin Boffemmyer <flux AT sourcemage.org>
Commit: Justin Boffemmyer <flux AT sourcemage.org>

smgl/cauldron: new, Cauldron is now a spell

This spell installs the Cauldron script suite. You can select either the
cauldron scripts (for generating installation media) or the enchantment
sccripts (the run-time installer engine), or both. If enchantment is
installed, then you can also choose which of the installer interfaces
will be installed with it.

The code in this spell is currently less pretty than I would like it to
be, but it works (for now at least), with at least the potential for
easy forward maintainability. Of course improvements are welcome, but
make sure you know what you are doing with it before changing things, as
the cauldron scripts will actually rely on this spell when generating
ISOs.

The script does nothing in BUILD, has some basic depends info (needs to
be fleshed out more), and asks you what you want installed. Other than
that, the brunt of the work is done in INSTALL. Currently only the SCM
version is supported, as there are no Cauldron releases at this time.

diff --git a/ChangeLog b/ChangeLog
index 76eb4ac..a744bea 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,6 @@
+2010-06-04 Justin Boffemmyer <flux AT sourceamge.org>
+ * smgl/cauldron: new spell, the Cauldron script suite
+
2010-06-04 Vasil Yonkov <spirtbrat AT sourcemage.org>
* canto: new spell, An RSS/Atom newsreader that sucks less

diff --git a/smgl/cauldron/BUILD b/smgl/cauldron/BUILD
new file mode 100755
index 0000000..27ba77d
--- /dev/null
+++ b/smgl/cauldron/BUILD
@@ -0,0 +1 @@
+true
diff --git a/smgl/cauldron/CONFIGURE b/smgl/cauldron/CONFIGURE
new file mode 100755
index 0000000..999bfaa
--- /dev/null
+++ b/smgl/cauldron/CONFIGURE
@@ -0,0 +1,23 @@
+. $GRIMOIRE/FUNCTIONS &&
+
+config_query_multi CHOSEN_SCRIPTS\
+ "Which script suite(s) would you like to install?" \
+ "cauldron" \
+ "enchantment" &&
+
+config_query_multi INTERFACES \
+ "Which installer interfaces would you like installed?" \
+ "menu" \
+ "shell" &&
+
+config_query_string SCRIPT_BASE \
+ "What should the base path for the scripts be?" \
+ "/usr/share/smgl" &&
+
+config_query_string ETC_BASE \
+ "What should the base path for the config files be?" \
+ "/etc/smgl" &&
+
+config_query DOCUMENTATION \
+ "Install documentation (man pages, requires man be installed)?"
\
+ y
diff --git a/smgl/cauldron/DEPENDS b/smgl/cauldron/DEPENDS
new file mode 100755
index 0000000..a725edc
--- /dev/null
+++ b/smgl/cauldron/DEPENDS
@@ -0,0 +1,17 @@
+depends bash &&
+depends shadow &&
+
+if [[ "$VERSION" == SCM ]]
+then
+ depends git
+fi &&
+
+if [[ "$DOCUMENTATION" = 'y' ]]
+then
+ depends man
+fi &&
+
+suggest_depends cdrtools \
+ "" \
+ "" \
+ "needed to generate iso9660 filesystems for the cauldron scripts"
diff --git a/smgl/cauldron/DETAILS b/smgl/cauldron/DETAILS
new file mode 100755
index 0000000..d2bc8c5
--- /dev/null
+++ b/smgl/cauldron/DETAILS
@@ -0,0 +1,18 @@
+ SPELL=cauldron
+ VERSION=SCM
+ SOURCE_IGNORE=volatile
+ FORCE_DOWNLOAD=on
+ SOURCE="$SPELL-$VERSION.tar.bz2"
+SOURCE_DIRECTORY="$BUILD_DIRECTORY/$SPELL-$VERSION"
+ SOURCE_URL[0]=git://download.sourcemage.org/smgl/cauldron.git
+ WEB_SITE=http://www.sourcemage.org/Cauldron/
+ ENTERED=20100604
+ LICENSE[0]="GPL"
+ SHORT="Source Mage ISO and installer scripts"
+cat << EOF
+Cauldron is the suite of scripts for generating installation media (cauldron)
+typically in the form of iso9660 filesystems to be burned onto cdroms, and
the
+scripts which run as the installation interface during the install
+(enchantment). Both sets of scripts may be installed, or just one, as chosen
+during the spell CONFIGURE stage.
+EOF
diff --git a/smgl/cauldron/HISTORY b/smgl/cauldron/HISTORY
new file mode 100644
index 0000000..5b22985
--- /dev/null
+++ b/smgl/cauldron/HISTORY
@@ -0,0 +1,3 @@
+2010-06-04 Justin Boffemmyer <flux AT sourcemage.org>
+ * ALL: spell created
+
diff --git a/smgl/cauldron/INSTALL b/smgl/cauldron/INSTALL
new file mode 100755
index 0000000..a1f8309
--- /dev/null
+++ b/smgl/cauldron/INSTALL
@@ -0,0 +1,117 @@
+# path where the scripts and data will be based
+install_path="$INSTALL_ROOT/${SCRIPT_BASE#/}"
+# strip any unnecessary trailing '/' from install_path
+install_path="${install_path%/}"
+
+# path where the config files and etc. will be based
+etc_path="$INSTALL_ROOT/${ETC_BASE#/}"
+# strip any unnecessary trailing '/' from etc_path
+etc_path="${etc_path%/}"
+
+#--------------
+# installation functions
+#--------------
+function install_dir() {
+ local dir="$1"
+ local dest="${2:-$install_path}"
+
+ # create the directory
+ install -v -d -m 0755 "$dest/$dir"
+}
+
+function install_dir_files() {
+ local dir="$1"
+ local dest="${2:-$install_path}"
+
+ # install all the files in the provided dir (no child directories)
+ find "$dir" -maxdepth 1 -type f -exec install -v -m 0644 -t "$dest" '{}' \;
+}
+
+function install_dir_single() {
+ local dir="$1"
+ local dest="${2:-$install_path}"
+
+ # create the directory
+ install_dir "$dir" "$dest" &&
+ #install -v -d -m 0755 "$dest/$dir" &&
+
+ # install all the files in it (no child directories)
+ install_dir_files "$dir" "$dest/$dir"
+ #find "$dir" -maxdepth 1 -type f -exec install -v -m 0644 '{}'
"$dest"/'{}' \;
+}
+
+function install_dir_recursive() {
+ local dir="$1"
+ local dest="${2:-$install_path}"
+
+ # create the parent and all child directories
+ find "$dir" -type d -exec install -v -d -m 0755 "$dest"/'{}' \; &&
+
+ # install all the files for the directories
+ find "$dir" -type f -exec install -v -m 0644 '{}' "$dest"/'{}' \;
+}
+
+#--------------
+# common libraries
+#--------------
+function install_common() {
+ # install the common libraries
+ install_dir "common" "$install_path"
+ install_dir_files "lib" "$install_path/common"
+}
+
+#--------------
+# cauldron
+#--------------
+function install_cauldron() {
+ # install the ISO filesystem cleaners
+ install_dir_single "cauldron/cleaners"
+}
+
+#--------------
+# enchantment
+#--------------
+function install_enchantment() {
+ # install the installer modules
+ install_dir_recursive "enchantment/modules" &&
+
+ # install the selected installer interfaces
+ for installer in ${INTERFACES[@]}
+ do
+ install_dir_recursive "enchantment/$installer"
+ done
+}
+
+
+#--------------
+# MAIN
+#--------------
+
+install_common &&
+
+for selected in ${CHOSEN_SCRIPTS[@]}
+do
+ # install the library and data files
+ install_dir_single "$selected" &&
+
+ # install the config file(s)
+ install_dir "$selected" "$etc_path" &&
+ pushd "$selected/etc" &&
+ install_dir_recursive "." "$etc_path/$selected" &&
+ popd &&
+
+ # install any man pages
+ if [[ "$DOCUMENTATION" = 'y' ]]
+ then
+ for manpage in "$selected/doc"/*.[1-8]
+ do
+ # make sure the man dir exists for the needed category first
+ install -v -d -m 0755 "/usr/share/man${manpage##.}" &&
+ # install the man page
+ install -v -m 0644 "$manpage" "/usr/share/man${manpage##.}/"
+ done
+ fi &&
+
+ # perform any specific install procedures for the selected scripts
+ "install_${selected}"
+done



  • [SM-Commit] GIT changes to master grimoire by Justin Boffemmyer (bcfaa14db3fff798936d7bb32bf0beaa593fa0b5), Justin Boffemmyer, 06/03/2010

Archive powered by MHonArc 2.6.24.

Top of Page