added precommit hook
This commit is contained in:
1
.gitignore
vendored
1
.gitignore
vendored
@@ -1,2 +1,3 @@
|
||||
/build
|
||||
/node_modules
|
||||
/dump
|
||||
|
||||
4
Makefile
4
Makefile
@@ -55,3 +55,7 @@ emulator:
|
||||
.PHONY: webconsole
|
||||
webconsole:
|
||||
node console.js
|
||||
|
||||
.PHONY: format
|
||||
format:
|
||||
haxelib run formatter -s src
|
||||
15
pre-commit.sh
Executable file
15
pre-commit.sh
Executable file
@@ -0,0 +1,15 @@
|
||||
#!/usr/bin/env sh
|
||||
|
||||
# Run:
|
||||
# ln -s ../../pre-commit.sh .git/hooks/pre-commit
|
||||
|
||||
set -e
|
||||
|
||||
# format
|
||||
|
||||
make format
|
||||
|
||||
# build
|
||||
|
||||
make build
|
||||
|
||||
Reference in New Issue
Block a user