feat: add simple dev contrib

Signed-off-by: jolheiser <john.olheiser@gmail.com>
main
jolheiser 2024-03-25 17:04:07 -05:00
parent c0fb1e8988
commit 1b9796ed0b
Signed by: jolheiser
GPG Key ID: B853ADA5DA7BBF7A
1 changed files with 19 additions and 0 deletions

19
contrib/dev.nu 100644
View File

@ -0,0 +1,19 @@
def main [user = "jolheiser", base_url = "https://git.jolheiser.com", repos = ["ugit", "helix.drv", "tmpl"]] {
# Clean
try {
rm -r .ugit/
rm -r .ssh/
}
# SSH
mkdir .ssh
http get $"https://github.com/($user).keys" | save --force .ssh/authorized_keys
# Git
mkdir .ugit
for $repo in $repos {
git clone --bare $"($base_url)/($repo).git" $".ugit/($repo).git"
{"private": false, "description": $repo} | save $".ugit/($repo).git/ugit.json"
}
}