From 4ebcdc3ef1d1126ab7f7b0d1d64f9ce45b297b2f Mon Sep 17 00:00:00 2001 From: Nico Schottelius Date: Tue, 5 Apr 2011 16:25:13 +0200 Subject: [PATCH 1/3] find __package* -type f -exec sed -i 's/deinstalled/removed/g' {} \; Signed-off-by: Nico Schottelius --- conf/type/__package_apt/man.text | 4 ++-- conf/type/__package_pacman/man.text | 4 ++-- conf/type/__package_yum/man.text | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/conf/type/__package_apt/man.text b/conf/type/__package_apt/man.text index 0780124d..905bfb5f 100644 --- a/conf/type/__package_apt/man.text +++ b/conf/type/__package_apt/man.text @@ -17,7 +17,7 @@ manage packages. REQUIRED PARAMETERS ------------------- state:: - Either "installed" or "deinstalled". + Either "installed" or "removed". OPTIONAL PARAMETERS @@ -37,7 +37,7 @@ __package_apt zsh --state installed __package_apt webserver --state installed --name nginx # Remove obsolete package -__package_apt puppet --state deinstalled +__package_apt puppet --state removed -------------------------------------------------------------------------------- diff --git a/conf/type/__package_pacman/man.text b/conf/type/__package_pacman/man.text index 35a7e44c..28766581 100644 --- a/conf/type/__package_pacman/man.text +++ b/conf/type/__package_pacman/man.text @@ -17,7 +17,7 @@ packages. REQUIRED PARAMETERS ------------------- state:: - Either "installed" or "deinstalled". + Either "installed" or "removed". OPTIONAL PARAMETERS @@ -37,7 +37,7 @@ __package_pacman zsh --state installed __package_pacman python --state installed --name python2 # Remove obsolete package -__package_pacman puppet --state deinstalled +__package_pacman puppet --state removed -------------------------------------------------------------------------------- diff --git a/conf/type/__package_yum/man.text b/conf/type/__package_yum/man.text index b2f57606..c9cad340 100644 --- a/conf/type/__package_yum/man.text +++ b/conf/type/__package_yum/man.text @@ -18,7 +18,7 @@ slightly confusing error message "Error: Nothing to do". REQUIRED PARAMETERS ------------------- state:: - Either "installed" or "deinstalled". + Either "installed" or "removed". OPTIONAL PARAMETERS @@ -38,7 +38,7 @@ __package_yum zsh --state installed __package_yum python --state installed --name python2 # Remove obsolete package -__package_yum puppet --state deinstalled +__package_yum puppet --state removed -------------------------------------------------------------------------------- From ac976c9f703ad319ff246ae0e2778a3f668ed2db Mon Sep 17 00:00:00 2001 From: Nico Schottelius Date: Tue, 5 Apr 2011 16:25:27 +0200 Subject: [PATCH 2/3] find __package* -type f -exec sed -i 's/uninstalled/removed/g' {} \; Signed-off-by: Nico Schottelius --- conf/type/__package/man.text | 2 +- conf/type/__package_apt/gencode-remote | 2 +- conf/type/__package_pacman/gencode-remote | 2 +- conf/type/__package_yum/gencode-remote | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/conf/type/__package/man.text b/conf/type/__package/man.text index eeeceba0..46af7b3d 100644 --- a/conf/type/__package/man.text +++ b/conf/type/__package/man.text @@ -17,7 +17,7 @@ It dispatches the actual work to the package system dependant types. REQUIRED PARAMETERS ------------------- state:: - The state the package should be in, either "installed" or "uninstalled" + The state the package should be in, either "installed" or "removed" OPTIONAL PARAMETERS diff --git a/conf/type/__package_apt/gencode-remote b/conf/type/__package_apt/gencode-remote index e38653e9..aac9beb1 100755 --- a/conf/type/__package_apt/gencode-remote +++ b/conf/type/__package_apt/gencode-remote @@ -46,7 +46,7 @@ case "$state" in echo $aptget install \"$name\" fi ;; - uninstalled) + removed) # Remove only if existent if [ -n "$is_installed" ]; then echo $aptget remove \"$name\" diff --git a/conf/type/__package_pacman/gencode-remote b/conf/type/__package_pacman/gencode-remote index 536b7708..b31d097a 100755 --- a/conf/type/__package_pacman/gencode-remote +++ b/conf/type/__package_pacman/gencode-remote @@ -44,7 +44,7 @@ case "$state" in echo pacman "$pacopts" -S \"$name\" fi ;; - uninstalled) + removed) if [ "$pkg_version" ]; then echo pacman "$pacopts" -R \"$name\" fi diff --git a/conf/type/__package_yum/gencode-remote b/conf/type/__package_yum/gencode-remote index 033298b1..215a1ae5 100755 --- a/conf/type/__package_yum/gencode-remote +++ b/conf/type/__package_yum/gencode-remote @@ -39,7 +39,7 @@ case "$state" in echo yum $opts install \"$name\" fi ;; - uninstalled) + removed) if ! grep -q "$not_installed" "$__object/explorer/pkg_version"; then echo yum $opts remove \"$name\" fi From 1687d82c9d88874bda757da031ce32b5379e1a31 Mon Sep 17 00:00:00 2001 From: Nico Schottelius Date: Tue, 5 Apr 2011 16:26:56 +0200 Subject: [PATCH 3/3] ++changes in 1.6.0 Signed-off-by: Nico Schottelius --- doc/changelog | 2 ++ 1 file changed, 2 insertions(+) diff --git a/doc/changelog b/doc/changelog index cec4a11a..9672814f 100644 --- a/doc/changelog +++ b/doc/changelog @@ -3,6 +3,8 @@ * New type __debconf_set_selections * New explorer os_version * Fix Type __group in case of __group NAME syntax + * Fix __package* types: consistently name --state removed instead of + uninstalled or deinstalled * Type __package gained Fedora support * Removed --preseed support from __package_apt * explorer/os: gained Fedora support