summaryrefslogtreecommitdiff
path: root/scripts/dupe-finder.sh
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/dupe-finder.sh')
-rwxr-xr-xscripts/dupe-finder.sh12
1 files changed, 12 insertions, 0 deletions
diff --git a/scripts/dupe-finder.sh b/scripts/dupe-finder.sh
new file mode 100755
index 0000000..9ffae6d
--- /dev/null
+++ b/scripts/dupe-finder.sh
@@ -0,0 +1,12 @@
+#!/bin/bash
+
+# dupe-finder.sh: Output duplicate games in your database
+
+# We're setting the envvar here to enforce the -w argument to uniq
+result=$(VGSTASH_TABLE_WIDTH=80 vgstash list | uniq -D -f 2 -w 58)
+if [[ -z $result ]]; then
+ exit
+else
+ VGSTASH_TABLE_WIDTH=80 vgstash list | head -n 2
+ echo "$result"
+fi