Add a silent mode for make fetch. hwids-20120916
authorDiego Elio Pettenò <flameeyes@flameeyes.eu>
Mon, 17 Sep 2012 15:24:27 +0000 (08:24 -0700)
committerDiego Elio Pettenò <flameeyes@flameeyes.eu>
Mon, 17 Sep 2012 15:24:27 +0000 (08:24 -0700)
Makefile

index af9f9470dd1fce32c2d7dfc937f746fb4a1d4e07..08e8170d49207bc27d5ff362c7130c9c5b7a61df 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1,10 +1,18 @@
 # can be replaced with `wget -q -O -` if you want
-HTTPCAT = curl
+ifeq "$(V)" "0"
+  HTTPCAT = curl -s
+  STATUS = git status -s
+  Q=@
+else
+  HTTPCAT = curl
+  STATUS = git status
+  Q=
+endif
 
 fetch:
-       $(HTTPCAT) http://pci-ids.ucw.cz/v2.2/pci.ids.bz2 | bzcat > pci.ids
-       $(HTTPCAT) http://www.linux-usb.org/usb.ids.bz2 | bzcat > usb.ids
-       git status
+       $(Q)$(HTTPCAT) http://pci-ids.ucw.cz/v2.2/pci.ids.bz2 | bzcat > pci.ids
+       $(Q)$(HTTPCAT) http://www.linux-usb.org/usb.ids.bz2 | bzcat > usb.ids
+       $(Q)$(STATUS)
 
 PV ?= $(shell date +%Y%m%d)
 P = hwids-$(PV)