X-Git-Url: https://git.grml.org/?p=grml-debootstrap.git;a=blobdiff_plain;f=grml-debootstrap.clp;h=496626c4a785815d15176a5dca1cab787fc1be64;hp=40063cbad27c42a2e56c00569ec1aade8ce9223f;hb=d722e05c29b53a6325bc15130e5b9e8c52982500;hpb=73f5513fb3a7327532a9bbc73e97560a5da1bd5f diff --git a/grml-debootstrap.clp b/grml-debootstrap.clp index 40063cb..496626c 100644 --- a/grml-debootstrap.clp +++ b/grml-debootstrap.clp @@ -1,29 +1,22 @@ # -*- shell-script -*- - -# -# shell script command line parameter-processing for: -# -# grml-debootstrap - wrapper around debootstrap for installing plain Debian via -# grml -# -# @Author: Tong SUN -# @Release: $Revision: 1.2 $, under the BSD license -# @HomeURL: http://xpt.sourceforge.net/ -# - +# Filename: grml-debootstrap.clp +# Purpose: shell script command line parameter-processing for grml-debootstrap +# Authors: grml-team (grml.org), Tong Sun +# Bug-Reports: see http://grml.org/bugs/ +# License: This file is licensed under the GPL v2 or any later version. +################################################################################ # @WARNING: Do NOT modify this file without prior contacting the author. # This script is use for the command line *logic* processing. It should be # as dumb as possible. I.e., it should NOT be more complicated than # copy-paste-and-rename from existing code. All *business-logic* processing # should be handled in the main script, where it belongs. +################################################################################ - - -_opt_temp=`getopt --name grml-debootstrap -o +m:i:r:t:p:c:hv --long \ - mirror:,iso:,release:,target:,mntpoint:,debopt:,interactive,config:,packages::,debconf::,keep_src_list,hostname:,password:,bootappend:,groot:,grub:,help,version \ +_opt_temp=`getopt --name grml-debootstrap -o +m:i:r:t:p:c:d:vhV --long \ + mirror:,iso:,release:,target:,mntpoint:,debopt:,interactive,nodebootstrap,config:,confdir:,packages::,debconf::,keep_src_list,hostname:,password:,bootappend:,groot:,grub:,verbose,help,version \ -- "$@"` if [ $? != 0 ]; then - eerror "Try `grml-debootstrap --help' for more information."; eend 1; exit 1 + eerror "Try 'grml-debootstrap --help' for more information."; eend 1; exit 1 fi eval set -- "$_opt_temp" @@ -52,17 +45,23 @@ while :; do --interactive) # Use interactive mode (frontend). _opt_interactive=T ;; + --nodebootstrap) # Skip debootstrap, only do configuration to the target. + _opt_nodebootstrap=T + ;; # # == Configuration options --config|-c) # Use specified configuration file, defaults to /etc/debootstr shift; _opt_config="$1" ;; - --packages) # Install packages defined in /etc/debootstrap/packages. Optio + --confdir|-d) # Place of config files for debootstrap, defaults to /etc/debo + shift; _opt_confdir="$1" + ;; + --packages) # Install packages defined in /packages. Option arg: shift; _opt_packages="$1" _opt_packages_set=T ;; - --debconf) # Pre-seed packages using /etc/debootstrap/debconf-selections. + --debconf) # Pre-seed packages using /debconf-selections. Option shift; _opt_debconf="$1" _opt_debconf_set=T ;; @@ -87,10 +86,14 @@ while :; do ;; # == Other options + --verbose|-v) # Increase verbosity. + if [ "$_opt_verbose" ]; then _opt_verbose=`expr $_opt_verbose + 1` + else _opt_verbose=1; fi + ;; --help|-h) # Print this usage information and exit. _opt_help=T ;; - --version|-v) # Show summary of options and exit. + --version|-V) # Show summary of options and exit. _opt_version=T ;; --) @@ -103,5 +106,4 @@ while :; do shift done - -# End +## END OF FILE #################################################################