@@ -31,30 +31,48 @@ This is how we ended up with the following API to run your tasks.
3131` ./dev.sh sometask ` or ` dev sometask `
3232
3333Some functionality will only be provided by the helper, e.g. running an init.
34- As we do not want to confuse this additional functionality with running a task, we use UPPERCASE arguments for the helper API.
34+ As we do not want to confuse this additional functionality with running a task, we use UPPERCASE
35+ arguments prefixed with ` DSR ` for utils only provided by the ` dev ` command.
3536
36- Example: ` dev INIT ` to create the files needed in your project.
37-
38- ** You should not use UPPERCASE tasks in your ` dev.sh ` !**
37+ Example: ` dev DSR_INIT ` to create the files needed in your project.
3938
4039## Setup
4140
4241run ` brew install sandstorm/tap/dev-script-runner ` to install
4342
4443run ` brew upgrade sandstorm/tap/dev-script-runner ` to upgrade
4544
46- Go to your project root and run ` dev INIT ` to create a ` dev.sh ` and a ` dev_setup.sh ` with examples for different types of tasks.
45+ Go to your project root and run ` dev DSR_INIT ` to create a ` dev.sh ` and a ` dev_setup.sh ` with examples for different types of tasks.
4746The ` $@ ` at the end of your ` dev.sh ` dispatches the script arguments to a function (so ` dev sometask ` calls ` sometask ` ).
4847
4948The script is only picked up by the helper if ` DEV_SCRIPT_MARKER ` is present in the file.
5049
51- ## Usage
50+ ### Writing tasks
51+
52+ ``` bash
53+ # Sometask to help with something
54+ #
55+ # The first line of the comment block will be used in the task overview.
56+ # If you want to provide more details just add more lines ;)
57+ function sometask() {
58+ echo " TODO: implement sometask()"
59+ }
60+ ```
61+
62+ ** Tasks starting with ` _ ` are expected to be private and will be ignored**
5263
53- ` dev <TASK_NAME> [ARGUMENTS] ` to run a task
64+ ** You should not use UPPERCASE tasks in your ` dev.sh ` **
65+
66+ ### Documenting Tasks
67+
68+ This currently is WIP and will be improved in the future ;)
69+
70+ ## Usage
5471
55- ` dev INIT ` to create the files needed in your project
72+ run ` dev ` for more information.
5673
5774## TODOs
5875
5976* Autocompletion for tasks
6077* Testing
78+ * more features for documenting tasks -> e.g. support examples, params, ...
0 commit comments