Skip to content

Commit

Permalink
chore: add demo script to Makefile
Browse files Browse the repository at this point in the history
To run demo, run `make demo`.
  • Loading branch information
suin committed Nov 2, 2018
1 parent 29d159a commit 44d8a07
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -21,3 +21,30 @@ build: fmt

install: build
cp bin/$(APP_NAME) /usr/local/bin/$(APP_NAME)

demo: demo-prepare demo-exec

demo-prepare:
-rm -rf /tmp/git-remind-demo
mkdir -p /tmp/git-remind-demo
cd /tmp/git-remind-demo && \
git init myapp1 && \
git init --bare myapp2-origin.git && \
git clone /tmp/git-remind-demo/myapp2-origin.git myapp2 && \
git init myapp3 && \
cd /tmp/git-remind-demo/myapp1 && \
touch unstaged-file
cd /tmp/git-remind-demo/myapp2 && \
git commit --allow-empty -m commit1 && \
git push && \
git commit --allow-empty -m commit2

demo-exec:
@echo
@echo "==== D E M O ===="
@echo
@set -eux && \
export GIT_REMIND_PATHS='/tmp/git-remind-demo/*' && \
git-remind paths && \
git-remind status -a && \
git-remind status-notification

0 comments on commit 44d8a07

Please sign in to comment.