From 77a0eb6fe4dca909c6fe63f00b6793ba759f1a63 Mon Sep 17 00:00:00 2001 From: Tuncer Ayaz Date: Mon, 5 Nov 2012 20:08:48 +0100 Subject: Fix #56 (always-on recursion) Always-on recursive application of all rebar commands causes too many issues. Recursive application is required for: 1. dealing with dependencies: get-deps, update-deps, and compile of deps right after get-deps or update-deps 2. projects with a riak-like apps/ project structure and dev process The vast majority of projects are not structured like riak. Therefore, moving forward it's best to (by default) restrict recursive behavior to dealing with deps. This commit does that and also adds command line and rebar.config options for controlling or configuring recursion. Also, we introduce two meta commands: prepare-deps (equivalent to rebar -r get-deps compile) and refresh-deps (equivalent to rebar -r update-deps compile). riak-like projects can extend the list of recursive commands (to include 'eunit' and 'compile') by adding {recursive_cmds, [eunit, compile]} to rebar.config. --- priv/shell-completion/bash/rebar | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'priv/shell-completion/bash') diff --git a/priv/shell-completion/bash/rebar b/priv/shell-completion/bash/rebar index 7dc3b5e..375566c 100644 --- a/priv/shell-completion/bash/rebar +++ b/priv/shell-completion/bash/rebar @@ -6,7 +6,7 @@ _rebar() COMPREPLY=() cur="${COMP_WORDS[COMP_CWORD]}" prev="${COMP_WORDS[COMP_CWORD-1]}" - sopts="-h -c -v -V -f -D -j -C -p -k" + sopts="-h -c -v -V -f -D -j -C -p -k -r" lopts="--help \ --commands \ --verbose \ @@ -15,6 +15,7 @@ _rebar() --config \ --profile \ --keep-going \ + --recursive \ --version" cmdsnvars="check-deps \ clean \ @@ -35,7 +36,9 @@ _rebar() help \ list-deps \ list-templates \ + prepare-deps \ qc \ + refresh-deps \ update-deps \ version \ xref \ -- cgit v1.1