Kook 0.7.1
task automation tool for Python, similar to Make, Rake, Ant, or Cook
pyKook is a very useful tool to control your task such as compile, install or clean. pyKook is similar to Make, Rake, Ant, or Cook. Kookbook.py, which is a task definition file for pyKook, is written in Python.
Simple Example of Kookbook.py:
@recipe
def hello(c):
print("Hello")
Output Result:
bash> kk hello # or pykook hello ### * hello (recipe=hello) Hello
Other Example of Kookbook.py:
CC = prop('CC', 'gcc -Wall')
kookbook.default = 'all'
@recipe
@ingreds('hello') # ingredients
def all(c): # or task_all(c)
pass
@recipe('*.o', ['$(1).c', '$(1).h']) # @recipe(product, [ingredients])
def file_o(c):
"""compile *.c and *.h into *.o"""
system(c%'$(CC) -c $(ingred)')
@recipe('hello', ['hello.o']) # @recipe(product, [ingredients])
def file_hello(c):
"""create 'hello' command"""
system(c%'$(CC) -o $(product) $(ingred)')
@recipe
def clean(c):
rm_rf("**/*.o", "**/*~")
## or
kookbook.load('@kook/books/clean.py') # load 'clean' and 'sweep' recipes
CLEAN.append("**/*.o")
See User's Guide for details.
| File | Type | Py Version | Uploaded on | Size | # downloads |
|---|---|---|---|---|---|
| Kook-0.7.1-py2.4.egg (md5) | Python Egg | 2.4 | 2011-11-10 | 77KB | 286 |
| Kook-0.7.1-py3.0.egg (md5) | Python Egg | 3.0 | 2011-11-10 | 76KB | 325 |
| Kook-0.7.1.tar.gz (md5) | Source | 2011-11-10 | 184KB | 267 | |
- Author: makoto kuwata
- Home Page: http://www.kuwata-lab.com/kook/
- Download URL: http://pypi.python.org/packages/source/K/Kook/Kook-0.7.1.tar.gz
- License: MIT License
- Platform: any
-
Categories
- Development Status :: 4 - Beta
- Environment :: Console
- Intended Audience :: Developers
- License :: OSI Approved :: MIT License
- Operating System :: OS Independent
- Programming Language :: Python
- Programming Language :: Python :: 2.4
- Programming Language :: Python :: 2.5
- Programming Language :: Python :: 2.6
- Programming Language :: Python :: 2.7
- Programming Language :: Python :: 3
- Programming Language :: Python :: 3.0
- Programming Language :: Python :: 3.1
- Programming Language :: Python :: 3.2
- Topic :: Software Development :: Libraries :: Python Modules
- Package Index Owner: kwatch
- DOAP record: Kook-0.7.1.xml
