From 3e88cb43928e2368acd669913c3bf32693174764 Mon Sep 17 00:00:00 2001 From: n-peugnet Date: Thu, 30 Sep 2021 18:06:15 +0200 Subject: run dna-backup on different commits --- exp/Makefile | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) (limited to 'exp/Makefile') diff --git a/exp/Makefile b/exp/Makefile index 37fa8c8..f5a9a4c 100644 --- a/exp/Makefile +++ b/exp/Makefile @@ -1,21 +1,23 @@ REPO_URL := https://club1.fr/~nicolas/git/dna-backup/ +TEMP_TEMPLATE := dna-backup-bench-XXXXX +MKTEMP := mktemp --tmpdir -d $(TEMP_TEMPLATE) + REPO_PATH := repo GIT_PATH := git GITC := git -C $(REPO_PATH) -BIN_PATH := .. - .PHONY: apply -apply: commits ../dna-backup +apply: TEMP := $(shell $(MKTEMP)) +apply: commits + $(MAKE) -C .. dna-backup cat $< | while read i; do \ $(GITC) checkout `echo "$$i" | cut -f1`; \ + ../dna-backup commit -v 2 $(REPO_PATH) $(TEMP); \ done + du -bad 2 $(TEMP) -$(BIN_PATH)/dna-backup: .FORCE - $(MAKE) -C $(BIN_PATH) dna-backup - -commits: Makefile repo git +commits: Makefile | repo git $(GITC) log --reverse --no-merges --pretty=tformat:"%H %as" \ | sort --unique --key=2 \ > $@ -- cgit v1.2.3