Skip to content

Commit

Permalink
Fix echoing to stderr
Browse files Browse the repository at this point in the history
Previously this was creating files called `1` on peoples disks 🤦
  • Loading branch information
lfdebrux committed Mar 5, 2021
1 parent 9cbb656 commit 4402dc9
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,12 @@
.DEFAULT_GOAL := bootstrap

%:
@[ -z $$TERM ] || tput setaf 1 # red
@echo 2>1 warning: calling '`make`' is being deprecated in this repo, you should use '`invoke` (https://pyinvoke.org)' instead.
@[ -z $$TERM ] || tput setaf 9 # default
-@[ -z "$$TERM" ] || tput setaf 1 # red
@>&2 echo warning: calling '`make`' is being deprecated in this repo, you should use '`invoke` (https://pyinvoke.org)' instead.
-@[ -z "$$TERM" ] || tput setaf 9 # default
@# pass goals to '`invoke`'
invoke $(or $(MAKECMDGOALS), $@)
@exit

help:
invoke --list
Expand All @@ -15,6 +16,6 @@ help:
bootstrap:
pip install digitalmarketplace-developer-tools
@echo done
@[ -z $$TERM ] || tput setaf 2 # green
@echo 2>1 dmdevtools has been installed globally, run developer tasks with '`invoke`'
@[ -z $$TERM ] || tput setaf 9 # default
-@[ -z "$$TERM" ] || tput setaf 2 # green
@>&2 echo dmdevtools has been installed globally, run developer tasks with '`invoke`'
-@[ -z "$$TERM" ] || tput setaf 9 # default

0 comments on commit 4402dc9

Please sign in to comment.