Added helper 'make' target which automatically produces 'tar.xz' source archive. The 'tar.xz' format will replace the current 'zip' format.

This commit is contained in:
Ivan Davidov 2016-05-04 21:38:11 +03:00
parent fcb0eeb3d4
commit 1baa860c2d
2 changed files with 12 additions and 3 deletions

4
.gitignore vendored
View File

@ -6,9 +6,7 @@
/src/source/**
/src/work/**
/src/*.iso
/src/*.img
/src/*.log
/src/minimal_linux_live*
/docs/mdbook
/docs/book/**

View File

@ -27,12 +27,23 @@ qemu:
@echo "Launching QEMU..."
@if [ "$(shell uname -m)" = "x86_64" ]; then sh qemu64.sh; else sh qemu32.sh; fi
src:
@echo "Generating source archive..."
@rm -f minimal_linux_live_*_src.tar.xz
@mkdir -p work
@sh 01_prepare_src.sh 1>/dev/null
@$(eval DATE_PARSED := $(shell LANG=en_US ; date +"%d-%b-%Y"))
@cd work/src && tar -cpf - `ls -A` | xz - > ../../minimal_linux_live_$(DATE_PARSED)_src.tar.xz && cd ../..
@echo "Source archive: minimal_linux_live_$(DATE_PARSED)_src.tar.xz"
help:
@echo ""
@echo " make all clean the workspace and then generate \"minimal_linux_live.iso\""
@echo ""
@echo " make clean remove all generated files"
@echo ""
@echo " make src generate 'tar.xz' source archive"
@echo ""
@echo " make qemu run \"Minimal Linux Live\" in qemu"
@echo ""
@echo " make help this is the default target"