summaryrefslogtreecommitdiff
path: root/artix/home/.local/bin/gitzero
diff options
context:
space:
mode:
authorNantha Sorubakanthan <nantha@mielota.com>2026-04-13 21:45:43 +0200
committerNantha Sorubakanthan <nantha@mielota.com>2026-04-13 21:45:43 +0200
commit0c913f1e421b9d47c052350c4c1d619e4ac6a297 (patch)
treec9124ff04b9252836221c41d2ca2fa133d166251 /artix/home/.local/bin/gitzero
Initial commit
Diffstat (limited to 'artix/home/.local/bin/gitzero')
-rwxr-xr-xartix/home/.local/bin/gitzero18
1 files changed, 18 insertions, 0 deletions
diff --git a/artix/home/.local/bin/gitzero b/artix/home/.local/bin/gitzero
new file mode 100755
index 0000000..6006f50
--- /dev/null
+++ b/artix/home/.local/bin/gitzero
@@ -0,0 +1,18 @@
+#! /bin/sh
+
+read -p "You really want to nuke your remote repo? (yes/no) $(git remote get-url origin) " confirmation
+
+if [ "$confirmation" = "yes" ]; then
+ mv .git/config .
+ rm -rf .git
+ git init
+ rm .git/config
+ mv config .git/
+ echo "I will push to :"
+ git remote get-url origin
+ git add .
+ git commit -m "Initial commit"
+ git push -u --force origin main
+else
+ echo "Abort."
+fi