This repository was archived by the owner on Aug 17, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathTaskfile
More file actions
37 lines (34 loc) · 1.45 KB
/
Taskfile
File metadata and controls
37 lines (34 loc) · 1.45 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
#!/bin/bash
PATH=./node_modules/.bin:$PATH
################################################################################
################################### HELPERS ####################################
################################################################################
function print_row {
printf " %-10s %-10s\n" "$1" "$2"
}
################################################################################
################################### TASKS ###################################
################################################################################
function task:app-cli {
# shellcheck disable=SC2068
app-cli $@
}
################################################################################
################################### TASKFILE ###################################
################################################################################
function task:default {
task:help
}
function task:help {
echo "$0 <task> <args>"
echo "Tasks:"
# We pick out the `task:*` functions
compgen -A function | sed -En 's/task:(.*)/\1/p' | cat -n
}
TIMEFORMAT="Task completed in %3lR"
# shellcheck disable=SC2145
time (task:"${@:-default}" && echo "")
################################################################################v
##################################### REFS #####################################
################################################################################
# https://github.com/adriancooney/Taskfile