X-Git-Url: http://git.cielonegro.org/gitweb.cgi?a=blobdiff_plain;f=GNUmakefile;h=e38637daae86ac9fb782222d2387e8dd7efa973d;hb=606fc17d6a055b9fc6fb8dcb62342a193f161962;hp=6ffe0fb4d069b792a43f138aa6dc92880755d68b;hpb=5444b919b19623d79b59d91b1511205a42653b54;p=sugar.git diff --git a/GNUmakefile b/GNUmakefile index 6ffe0fb..e38637d 100644 --- a/GNUmakefile +++ b/GNUmakefile @@ -3,12 +3,17 @@ help: @echo " .:. Sugar - The Dot-Files Manager .:." @echo @echo "Usage:" - @echo " make lint - lint The Sugar System" - @echo " make update - update repository with the current dot files" - @echo " make commit - commit changes to the repository" - @echo " make install - update the current dot files with the repository" + @echo " make lint - lint The Sugar System." + @echo " make update - update repository with the current dot files." + @echo " make commit - commit changes to the repository." + @echo " make install - update the current dot files with the repository." @echo " make import FILES=" - @echo " - import the dot files into the repository" + @echo " - import the dot files into the repository." + @echo " make import-all" + @echo " - import every uncontrolled dot files, which aren't" + @echo " ignored, into the repository." + @echo " make diff FILE=" + @echo " - show diff of the dot file." @echo lint: @@ -21,7 +26,7 @@ update: git pull perl ./tools/list-files.pl | perl ./tools/update.pl perl ./tools/list-files.pl | perl ./tools/find-outdated.pl - git status + -git status commit: git add -A @@ -39,8 +44,25 @@ import: @exit 1 else import: - perl ./tools/import.pl $(FILES) + (for i in $(FILES); do echo $$i; done) | perl ./tools/import.pl + -git status +endif + +import-all: + perl ./tools/list-files.pl | \ + perl ./tools/find-missing.pl | \ + cut -b 3- | \ + perl ./tools/import.pl -git status + +ifeq ($(FILE),) +diff: + @echo "Specify one file." + @echo "Usage: make diff FILE=" + @exit 1 +else +diff: + perl ./tools/diff.pl $(FILE) | $(PAGER) endif -.PHONY: help lint update commit install import +.PHONY: help lint update commit install import diff