tazpkg rev 56
Add: reconfigure command + typo
author | Eric Joseph-Alexandre <erjo@slitaz.org> |
---|---|
date | Thu Feb 28 15:35:49 2008 +0100 (2008-02-28) |
parents | 77cd0a789c38 |
children | b42f580d6653 |
files | tazpkg |
line diff
1.1 --- a/tazpkg Wed Feb 27 23:43:51 2008 +0100 1.2 +++ b/tazpkg Thu Feb 28 15:35:49 2008 +0100 1.3 @@ -87,7 +87,7 @@ 1.4 \033[1mCommands: \033[0m 1.5 usage Print this short usage. 1.6 list List installed packages on the system by category or all. 1.7 - xhtml-list Creat a xHTML list of installed packges. 1.8 + xhtml-list Creates a xHTML list of installed packges. 1.9 list-mirror List all available packages on the mirror (--diff for new). 1.10 info Print informations about the package. 1.11 desc Print description of a package (if it exist). 1.12 @@ -100,14 +100,15 @@ 1.13 extract Extract a (*.tazpkg) package into a directory. 1.14 pack Pack an unpacked or prepared package tree. 1.15 recharge Recharge your packages.list from the mirror. 1.16 - repack Creat a package archive from an installed package. 1.17 + repack Creates a package archive from an installed package. 1.18 upgrade Upgrade all installed and listed packages on the mirror. 1.19 block|unblock Block an installed package version or unblock it for upgrade. 1.20 get Download a package into the current directory. 1.21 get-install Download and install a package from the mirror. 1.22 check Verify installed packages concistancy. 1.23 clean-cache Clean all packages downloaded in cache directory. 1.24 - setup-mirror Change the mirror url configuration." 1.25 + setup-mirror Change the mirror url configuration. 1.26 + reconfigure Replay post install script from package." 1.27 } 1.28 1.29 # Status function with color (supported by Ash). 1.30 @@ -1269,6 +1270,25 @@ 1.31 fi 1.32 echo "" 1.33 ;; 1.34 + reconfigure) 1.35 + # Replay post_install from receipt 1.36 + # 1.37 + check_for_package_on_cmdline 1.38 + check_root 1.39 + if [ -d "$INSTALLED/$PACKAGE" ]; then 1.40 + check_for_receipt 1.41 + # Check for post_install 1.42 + if grep -q ^post_install $INSTALLED/$PACKAGE/receipt; then 1.43 + . $INSTALLED/$PACKAGE/receipt 1.44 + post_install 1.45 + else 1.46 + echo -e "\nNothing to do for $PACKAGE." 1.47 + fi 1.48 + else 1.49 + echo -e "\npackage $PACKAGE is not installed." 1.50 + echo -e "Install package with 'tazpkg install' or 'tazpkg get-install'\n" 1.51 + fi 1.52 + ;; 1.53 shell) 1.54 # Tazpkg SHell 1.55 #