# HG changeset patch # User Christophe Lincoln # Date 1304725464 -7200 # Node ID e1a3c5900648d519ef29eca685087d99e8d5904b # Parent a491bec2d20aa3e7a423acfbde66fa344dcfd00e cook: Add option --getsrc (Thanks Christopher) diff -r a491bec2d20a -r e1a3c5900648 cook --- a/cook Fri May 06 23:41:09 2011 +0100 +++ b/cook Sat May 07 01:44:24 2011 +0200 @@ -37,7 +37,8 @@ $(echo -e "\033[1m$(gettext "Options:")\033[0m") --clean|-c Cook : $(gettext "clean the package in the wok.") - --install|-i Cook : $(gettext "and install the package.") + --install|-i Cook : $(gettext "cook and install the package.") + --getsrc|-gs Cook : $(gettext "get the package source tarball.") --wok|-w Setup: $(gettext "create also a wok from Hg repo.") EOT @@ -651,6 +652,11 @@ status && echo "" && exit 0 ;; --install|-i) inst='yes' ;; + --getsrc) + echo "Getting source for: $pkg" + separator + . $WOK/$pkg/receipt && get_source + echo -e "Tarball: $SRC/$TARBALL\n" && exit 0 ;; esac # Check if wanted is build now so we have separate log files. diff -r a491bec2d20a -r e1a3c5900648 doc/cookutils.en.html --- a/doc/cookutils.en.html Fri May 06 23:41:09 2011 +0100 +++ b/doc/cookutils.en.html Sat May 07 01:44:24 2011 +0200 @@ -31,8 +31,9 @@

Cook usage

- Cook provide a small built-in help usage that you can display with - the command: + Cook provide a small built-in help usage that you can display with the + command 'usage'. It also have some options to perform special task on + a package, rater before cooking it or after. To get help and usage:

 # cook usage
@@ -49,11 +50,11 @@
 # tazdev gen-chroot && tazdev chroot
 

- By default Tazdev create a chrrot in /home/slitaz/cooking/chroot but you + By default Tazdev create a chroot in /home/slitaz/cooking/chroot but you can specify a custome path in argument. The chroot place is not important, when you will be in the chroot you will use standard SliTaz path such as /home/slitaz/wok for the wok directory or /home/slitaz/log for all the cook - logs. As usual you can diplay tazdev help usage with: tazdev usage + logs. As usual you can diplay tazdev help usage with: tazdev usage.

Getting started

@@ -107,13 +108,26 @@

If all went well you will find your packages in $SLITAZ/packages - directory and produced files in $SLITAZ/wok/pkgname. If you want to cook - and install the package in one command: + directory and produced files in $SLITAZ/wok/pkgname. +

+ +

Cook and install

+

+ If you want to cook and install the package in one command:

 # cook pkgname --install
 
+

Get sources

+

+ If you want or need to download only the sources of a package but without + building it, you can use the option --getsrc as bellow: +

+
+# cook pkgname --getsrc
+
+

Clean packages

After compilation and packaging ther is several files in the wok that take