Skip to content
This repository has been archived by the owner on Jul 22, 2021. It is now read-only.
/ clack Public archive

Run multiple iterations of the same command from a stored configuration

License

Notifications You must be signed in to change notification settings

borntyping/clack

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

clack

clack on PyPI clack on PyPI Documentation for clack on Read The Docs Travis-CI build status for clack GitHub issues for clack

Run multiple iterations of the same command from a stored configuration.

I built this to help with building multiple packages using fpm. I had a set of commands where it was useful to share default and common arguments for each package, and the commands were complex enough that I wanted a configuration file describing them (and generic functions are painful in make). An example of using clack with fpm can be found in examples/fpm.json.

Usage

Create a configuration file:

{
    "default": {
        "command": "cowsay",
        "options": { "-f": "default" }
    },
    "iterations": [
        {
            "arguments": ["moo"]
        },
        {
            "arguments": ["baa"],
            "options": { "-f": "sheep" }
        }
    ]
}

Then run clack on the file:

clack examples/farm.json

And the result:

 _____
< moo >
 -----
        \   ^__^
         \  (oo)\_______
            (__)\       )\/\
                ||----w |
                ||     ||
 _____
< baa >
 -----
  \
   \
       __
      UooU\.'@@@@@@`.
      \__/(@@@@@@@@@@)
           (@@@@@@@@)
           `YY~~~~YY'
            ||    ||

Installation

Install clack with pip or pipsi.

pip install clack

Licence

clack is licensed under the MIT Licence.

Authors

clack was written by Sam Clements.

About

Run multiple iterations of the same command from a stored configuration

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages