aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTeddy Wing2018-02-12 23:01:08 +0100
committerTeddy Wing2018-02-12 23:01:08 +0100
commit2719b487418e90a14514c190f9d5362f85717de9 (patch)
treebcc087b5d985c5300f4ca3ca160ff2bb2a3cdd45
parentb25764a4bfc9cdc79db7baa707c58ee32c510347 (diff)
parent2ec7252024d85620611a1834b298308ec6179f02 (diff)
downloadharvester-2719b487418e90a14514c190f9d5362f85717de9.tar.bz2
Merge branch 'implement-list-modules'
-rwxr-xr-xharvester14
1 files changed, 12 insertions, 2 deletions
diff --git a/harvester b/harvester
index 605ba14..30b2996 100755
--- a/harvester
+++ b/harvester
@@ -56,6 +56,15 @@ function hcl_log () {
hcl log "$date" "@${project}" "$time" "$description"
}
+function list_modules () {
+ local project="$1"
+
+ local project_id=$(grep "$project" $HOME/.hcl/settings.yml |
+ cut -d ' ' -f 2)
+
+ hcl tasks | grep "^${project_id}"
+}
+
function main () {
local project=''
local time='7'
@@ -113,8 +122,9 @@ function main () {
continue
;;
--list-modules)
- shift
- continue
+ list_modules "$project"
+
+ return 0
;;
--help)
print_usage