Notice: the grml team is migrating from Mercurial to Git.
Please visit git.grml.org instead!
| author | Michael Prokop <mika@grml.org> |
| Sun May 13 11:15:55 2007 +0200 (18 months ago) | |
| changeset 9 | 319ec03c7ff0 |
| manifest | 319ec03c7ff0 |
| parent 8 | 794f498f28b9 |
| child 10 | 195af8e94a8e |
--- a/debian/changelog Fri Mar 16 20:03:26 2007 +0100+++ b/debian/changelog Sun May 13 11:15:55 2007 +0200@@ -1,3 +1,11 @@ grml-saveconfig (0.2.3) unstable; urgenc+grml-saveconfig (0.2.4) unstable; urgency=low++ * Added support for option '-grmlhome': store hidden files from+ $HOME of user grml [use as user root].+ [Testing: issue204]++ -- Michael Prokop <mika@grml.org> Sun, 13 May 2007 11:13:02 +0200+grml-saveconfig (0.2.3) unstable; urgency=low* Rewrote partition handling so it works with fs-labels as well.
--- a/grml-config.txt Fri Mar 16 20:03:26 2007 +0100+++ b/grml-config.txt Sun May 13 11:15:55 2007 +0200@@ -72,6 +72,7 @@ specifying which parts should be saved ispecifying which parts should be saved in the configuration file:-home store hidden files from $HOME ($HOME/.*)+ -grmlhome store hidden files from \$HOME (\$HOME/.*) of user grml [use as user root]-etc store modified files from /etc-configdir store $HOME/config-all store all configuration files (:= -home, -configdir and -etc)@@ -106,6 +107,7 @@ should be extracted.should be extracted.-home extract hidden files from $HOME ($HOME/.*)+ -grmlhome store hidden files from \$HOME (\$HOME/.*) of user grml [use as user root]-etc extract modified files from /etc-configdir extract $HOME/config
--- a/restore-config Fri Mar 16 20:03:26 2007 +0100+++ b/restore-config Sun May 13 11:15:55 2007 +0200@@ -4,7 +4,7 @@# Authors: grml-team (grml.org), (c) Michael Prokop <mika@grml.org># Bug-Reports: see http://grml.org/bugs/# License: This file is licensed under the GPL v2.-# Latest change: Tue Oct 18 15:54:43 CEST 2005 [mika]+# Latest change: Son Mai 13 11:12:38 CEST 2007 [mika]################################################################################# some zsh-stuff {{{@@ -45,6 +45,7 @@ usage()$bg[black]$fg[blue]${boldcolor}Target options:${reset_color}-home extract hidden files from \$HOME (\$HOME/.*)+ -grmlhome store hidden files from \$HOME (\$HOME/.*) of user grml [use as user root]-etc extract modified files from /etc-configdir extract \$HOME/config@@ -80,6 +81,11 @@ restore_home(){( cd $HOME && unp $FILENAME -- -x $HOME )}+restore_grmlhome(){+ echo "Trying to extract $FILENAME in /home/grml"+ ( cd /home/grml/ && unp $FILENAME -- -x /home/grml )+}+restore_etc(){echo "Trying to extract $FILENAME in /etc"( cd /etc && unp $FILENAME -- -x /etc )@@ -114,6 +120,11 @@ parse_options()RESTORE_HOME="yes"fi+ if [[ "$o_grmlhome" != "" ]]; then+ echo "debug: grmlhome is set"+ RESTORE_GRMLHOME="yes"+ fi+if [[ "$o_etc" != "" ]]; thenecho "debug: etc is set"RESTORE_ETC="yes"@@ -132,6 +143,11 @@ runit(){if [[ $RESTORE_HOME == "yes" ]]; thendebug "running restore_home"restore_home+ RESTORE_SET=1+ fi+ if [[ $RESTORE_GRMLHOME == "yes" ]]; then+ debug "running restore_grmlhome"+ restore_grmlhomeRESTORE_SET=1fiif [[ $RESTORE_ETC == "yes" ]] ; then
--- a/save-config Fri Mar 16 20:03:26 2007 +0100+++ b/save-config Sun May 13 11:15:55 2007 +0200@@ -4,7 +4,7 @@# Authors: grml-team (grml.org), (c) Michael Prokop <mika@grml.org># Bug-Reports: see http://grml.org/bugs/# License: This file is licensed under the GPL v2.-# Latest change: Mon Mär 12 12:13:09 CET 2007 [mika]+# Latest change: Son Mai 13 11:08:15 CEST 2007 [mika]################################################################################# some zsh-stuff {{{@@ -65,12 +65,13 @@ usage()$bg[black]$fg[blue]${boldcolor}Files-to-store options:${reset_color}-home store hidden files from \$HOME (\$HOME/.*)+ -grmlhome store hidden files from \$HOME (\$HOME/.*) of user grml [use as user root]-etc store modified files from /etc-configdir store \$HOME/config-all store all configuration files (:= -home, -configdir and -etc)Notice: it is also possible to use environment variables:- \$SAVE_HOME, \$SAVE_ETC, \$SAVE_CONFIGDIR and \$SAVE_ALL+ \$SAVE_HOME, \$SAVE_GRMLHOME, \$SAVE_ETC, \$SAVE_CONFIGDIR and \$SAVE_ALL$bg[black]$fg[blue]${boldcolor}Usage examples:${reset_color}$PROGRAMNAME -all => store all configuration files in config.tbz in current dir@@ -94,6 +95,12 @@ save_home(){save_home(){debug "save home"for i in $HOME/.* ; do findchanged "$i" /etc/skel/$(basename "$i"); done >> $TMP_FILELIST+ debug "debug: $TMP_FILELIST"+}++save_grmlhome(){+ debug "save grmlhome"+ for i in /home/grml/.* ; do findchanged "$i" /etc/skel/$(basename "$i"); done >> $TMP_FILELISTdebug "debug: $TMP_FILELIST"}@@ -145,6 +152,11 @@ parse_options()SAVE_HOME="yes"fi+ if [[ "$o_grmlhome" != "" ]]; then+ debug "grmlhome is set"+ SAVE_GRML_HOME="yes"+ fi+if [[ "$o_etc" != "" ]]; thendebug "etc is set"SAVE_ETC="yes"@@ -156,8 +168,9 @@ parse_options()fiif [[ "$o_all" != "" ]]; then- debug "home, etc and configdir are set"+ debug "home, grmlhome, etc and configdir are set"SAVE_HOME="yes"+ SAVE_GRMLHOME="yes"SAVE_ETC="yes"SAVE_CONFIGDIR="yes"fi@@ -183,6 +196,11 @@ runit(){save_homeSETSAVE=1fi+ if [[ $SAVE_GRMLHOME == "yes" ]]; then+ debug "running save_grmlhome"+ save_grmlhome+ SETSAVE=1+ fiif [[ $SAVE_ETC == "yes" ]] ; thendebug "running save_etc"save_etc
--- a/save-config.1 Fri Mar 16 20:03:26 2007 +0100+++ b/save-config.1 Sun May 13 11:15:55 2007 +0200@@ -63,6 +63,7 @@ This script generates a plain bzip2 comp.nf\-home store hidden files from $HOME ($HOME/\&.*)+\-grmlhome store hidden files from \\$HOME (\\$HOME/\&.*) of user grml [use as user root]\-etc store modified files from /etc\-configdir store $HOME/config\-all store all configuration files (:= \-home, \-configdir and \-etc)@@ -103,6 +104,7 @@ You can restore a configuration using th.nf\-home extract hidden files from $HOME ($HOME/\&.*)+\-grmlhome store hidden files from \\$HOME (\\$HOME/\&.*) of user grml [use as user root]\-etc extract modified files from /etc\-configdir extract $HOME/config.fi