radare2/mk/hg-utils.mk
pancake bca428f994 * Some ideas for the code analysis module
* Fix r_iter_last()
  - Some more work on the Vala integration
* Grep for README and TODO for hg-miss
2009-08-24 12:03:37 +00:00

25 lines
845 B
Makefile

# radare :: pancake // nopcode.org
# Makefile helpers for mercurial
hg-miss:
@-hg st . | grep -e vala$$ -e mk$$ | grep ^? | grep -v config-user | cut -c 2- || true
@-hg st . | grep -e \\.c$$ -e \\.h$$ | grep -v vapi | grep ^? | grep -v r_userconf | cut -c 2- || true
@-hg st . | grep -e \\.vapi$$ -e \\.acr$$ -e README$$ -e TODO$$ | grep ^? | cut -c 2- || true
FILES?=
hg-locdiff:
@A=`hg diff ${FILES} | grep -v '+++' | grep ^+ |wc -l` ; \
B=`hg diff ${FILES} | grep -v -- '---' | grep ^- |wc -l` ; \
echo $$((A-B))
hg-help:
@echo "hg-utils.mk mercurial utilities"
@echo "-----------.-------------------"
@echo "hg-miss | list interesting missing files"
@echo "hg-locdiff | count the difference of LOCs for current commit or FILES"
@echo " $$ hg-locdiff \"FILES=Makefile foo.c\""
hg-ci:
@hg diff > /tmp/diff
@hg ci