summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/main.sh7
1 files changed, 7 insertions, 0 deletions
diff --git a/scripts/main.sh b/scripts/main.sh
new file mode 100755
index 0000000..e8d006d
--- /dev/null
+++ b/scripts/main.sh
@@ -0,0 +1,7 @@
+#!/bin/bash
+set -e
+go build ./cmd/btrfs-rec
+if ! test -s ../scratch/dump.scan-for-nodes.json; then
+ time ./btrfs-rec --pv=../scratch/dump-zero.img inspect scan-for-nodes > ../scratch/dump.scan-for-nodes.json ||
+ { r=$?; rm -f ../scratch/dump.scan-for-nodes.json; exit $r; }
+fi