add quiet options
This commit is contained in:
16
Makefile
16
Makefile
@@ -45,20 +45,20 @@ install: $(BIN)
|
|||||||
endif
|
endif
|
||||||
|
|
||||||
doc:
|
doc:
|
||||||
$(MAKE) -C doc all
|
@$(MAKE) -C doc all
|
||||||
|
|
||||||
uninstall:
|
uninstall:
|
||||||
$(RM) $(PREFIX)$(PACKAGE)
|
@$(RM) $(PREFIX)$(PACKAGE)
|
||||||
|
|
||||||
clean:
|
clean:
|
||||||
$(RM) -r bin
|
@echo " CLEAN"
|
||||||
$(RM) -r build
|
@$(RM) -r bin
|
||||||
$(MAKE) -C doc clean
|
@$(RM) -r build
|
||||||
|
@$(MAKE) -C doc clean --no-print-directory
|
||||||
|
|
||||||
distclean: clean
|
distclean: clean
|
||||||
$(RM) config.mak config.status
|
@$(RM) config.mak config.status
|
||||||
$(RM) $(TARBALL)
|
@$(RM) $(TARBALL)
|
||||||
$(MAKE) -C doc clean
|
|
||||||
|
|
||||||
release: distclean all
|
release: distclean all
|
||||||
tar -czf $(TARBALL) $(RELEASE_FILES)
|
tar -czf $(TARBALL) $(RELEASE_FILES)
|
||||||
|
|||||||
18
doc/Makefile
18
doc/Makefile
@@ -1,22 +1,22 @@
|
|||||||
hello.info: hello.texi version.texi
|
hello.info: hello.texi version.texi
|
||||||
makeinfo --no-split hello.texi -o hello.info
|
@makeinfo --no-split hello.texi -o hello.info
|
||||||
|
|
||||||
hello.html: hello.texi version.texi
|
hello.html: hello.texi version.texi
|
||||||
makeinfo --no-split --html hello.texi
|
@makeinfo --no-split --html hello.texi
|
||||||
|
|
||||||
hello.pdf: hello.texi version.texi
|
hello.pdf: hello.texi version.texi
|
||||||
makeinfo --pdf hello.texi
|
@makeinfo --pdf hello.texi
|
||||||
|
|
||||||
hello.txt: hello.texi version.texi
|
hello.txt: hello.texi version.texi
|
||||||
makeinfo --plaintext hello.texi -o hello.txt
|
@makeinfo --plaintext hello.texi -o hello.txt
|
||||||
|
|
||||||
clean:
|
clean:
|
||||||
rm -f *.aux *.cp *.cps *.fn *.fns *.ky *.kys *.log *.pg *.pgs *.toc *.tp *.tps *.vr *.vrs
|
@rm -f *.aux *.cp *.cps *.fn *.fns *.ky *.kys *.log *.pg *.pgs *.toc *.tp *.tps *.vr *.vrs
|
||||||
rm -f hello.info hello.dvi hello.pdf hello.html hello.txt
|
@rm -f hello.info hello.dvi hello.pdf hello.html hello.txt
|
||||||
|
|
||||||
install: hello.info
|
install: hello.info
|
||||||
install -d $(DESTDIR)$(infodir)
|
@install -d $(DESTDIR)$(infodir)
|
||||||
install -m 644 hello.info $(DESTDIR)$(infodir)/
|
@install -m 644 hello.info $(DESTDIR)$(infodir)/
|
||||||
install-info --info-dir=$(DESTDIR)$(infodir) $(DESTDIR)$(infodir)/hello.info
|
@install-info --info-dir=$(DESTDIR)$(infodir) $(DESTDIR)$(infodir)/hello.info
|
||||||
|
|
||||||
.PHONY: all clean install
|
.PHONY: all clean install
|
||||||
|
|||||||
@@ -14,14 +14,18 @@ Usage: $me [OPTION]...
|
|||||||
Standard GCK cleanup
|
Standard GCK cleanup
|
||||||
|
|
||||||
Options:
|
Options:
|
||||||
|
-q, --quiet silence output
|
||||||
|
|
||||||
--help print this help and exit
|
--help print this help and exit
|
||||||
--version output version information"
|
--version output version information"
|
||||||
|
|
||||||
|
QUIET=
|
||||||
|
|
||||||
while test $# -gt 0; do
|
while test $# -gt 0; do
|
||||||
case $1 in
|
case $1 in
|
||||||
--help) echo "$usage"; exit 0;;
|
--help) echo "$usage"; exit 0;;
|
||||||
--version) echo "$version"; exit 0;;
|
--version) echo "$version"; exit 0;;
|
||||||
|
--quiet|-q) QUIET="--quiet";;
|
||||||
-*)
|
-*)
|
||||||
echo "$0: Unknown option '$1'." >&2
|
echo "$0: Unknown option '$1'." >&2
|
||||||
echo "$0: Try '--help' for more information.'$1'." >&2
|
echo "$0: Try '--help' for more information.'$1'." >&2
|
||||||
@@ -41,9 +45,11 @@ run() {
|
|||||||
|
|
||||||
[ -d "./git" ] && fatal "must be run from parent directory"
|
[ -d "./git" ] && fatal "must be run from parent directory"
|
||||||
|
|
||||||
run sh ./tools/format
|
run sh ./tools/format $QUIET
|
||||||
run rm -rf .cache
|
run rm -rf .cache
|
||||||
run rm -f compile_commands.json
|
run rm -f compile_commands.json
|
||||||
run make distclean
|
run make distclean
|
||||||
|
|
||||||
|
if [ -z "$QUIET" ]; then
|
||||||
echo "done."
|
echo "done."
|
||||||
|
fi
|
||||||
|
|||||||
@@ -14,14 +14,18 @@ Usage: $me [OPTION]...
|
|||||||
Format C source code
|
Format C source code
|
||||||
|
|
||||||
Options:
|
Options:
|
||||||
|
-q, -quiet silence output
|
||||||
|
|
||||||
--help print this help and exit
|
--help print this help and exit
|
||||||
--version output version information"
|
--version output version information"
|
||||||
|
|
||||||
|
QUIET=
|
||||||
|
|
||||||
while test $# -gt 0; do
|
while test $# -gt 0; do
|
||||||
case $1 in
|
case $1 in
|
||||||
--help) echo "$usage"; exit 0;;
|
--help) echo "$usage"; exit 0;;
|
||||||
--version) echo "$version"; exit 0;;
|
--version) echo "$version"; exit 0;;
|
||||||
|
--quiet|-q) QUIET=true;;
|
||||||
-*)
|
-*)
|
||||||
echo "$0: Unknown option '$1'." >&2
|
echo "$0: Unknown option '$1'." >&2
|
||||||
echo "$0: Try '--help' for more information.'$1'." >&2
|
echo "$0: Try '--help' for more information.'$1'." >&2
|
||||||
@@ -30,5 +34,10 @@ while test $# -gt 0; do
|
|||||||
shift
|
shift
|
||||||
done
|
done
|
||||||
|
|
||||||
|
if [ -z "$QUIET" ]; then
|
||||||
find . -type f -name '*.c' ! -path './lib/*' ! -path './gcklib/*' -exec clang-format -i --verbose {} +
|
find . -type f -name '*.c' ! -path './lib/*' ! -path './gcklib/*' -exec clang-format -i --verbose {} +
|
||||||
find . -type f -name '*.h' ! -path './lib/*' ! -path './gcklib/*' -exec clang-format -i --verbose {} +
|
find . -type f -name '*.h' ! -path './lib/*' ! -path './gcklib/*' -exec clang-format -i --verbose {} +
|
||||||
|
else
|
||||||
|
find . -type f -name '*.c' ! -path './lib/*' ! -path './gcklib/*' -exec clang-format -i {} +
|
||||||
|
find . -type f -name '*.h' ! -path './lib/*' ! -path './gcklib/*' -exec clang-format -i {} +
|
||||||
|
fi
|
||||||
|
|||||||
Reference in New Issue
Block a user