Skip to content

Commit 56c2d58

Browse files
committed
Makefile for handy commands
1 parent 5456ed2 commit 56c2d58

File tree

1 file changed

+43
-0
lines changed

1 file changed

+43
-0
lines changed

Makefile

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
# text reset
2+
NO_COLOR=\033[0m
3+
# green
4+
OK_COLOR=\033[32;01m
5+
# red
6+
ERROR_COLOR=\033[31;01m
7+
# cyan
8+
WARN_COLOR=\033[36;01m
9+
# yellow
10+
ATTN_COLOR=\033[33;01m
11+
12+
ROOT_DIR := $(shell git rev-parse --show-toplevel)
13+
14+
VERSION := `git describe --tags --dirty 2>/dev/null`
15+
COMMITHASH := `git rev-parse --short HEAD 2>/dev/null`
16+
DATE := `date "+%FT%T%z"`
17+
18+
.PHONY: all
19+
all: test
20+
21+
init:
22+
@echo "$(ATTN_COLOR)==> init $(NO_COLOR)"
23+
24+
.PHONY: test
25+
test:
26+
@echo "$(ATTN_COLOR)==> test $(NO_COLOR)"
27+
@tox -e py27,py37
28+
29+
.PHONY: test_smoke
30+
test_smoke:
31+
@echo "$(ATTN_COLOR)==> test_smoke $(NO_COLOR)"
32+
@tox -e py27,py37 -- -m smoke
33+
34+
.PHONY: test_smoke_no_app
35+
test_smoke_no_app:
36+
@echo "$(ATTN_COLOR)==> test_smoke_no_app $(NO_COLOR)"
37+
@tox -e py27,py37 -- -m "smoke and not app"
38+
39+
.PHONY: splunkrc
40+
splunkrc:
41+
@echo "$(ATTN_COLOR)==> splunkrc $(NO_COLOR)"
42+
@echo "To make a .splunkrc:"
43+
@echo " [SPLUNK_INSTANCE_JSON] | python scripts/build-splunkrc.py ~/.splunkrc"

0 commit comments

Comments
 (0)