Begin transition to codeberg

This commit is contained in:
Aminda Suomalainen 2024-08-10 12:46:33 +03:00
parent ae144a1132
commit 68286f804c
Signed by: Mikaela
SSH Key Fingerprint: SHA256:CXLULpqNBdUKB6E6fLA1b/4SzG0HvKD19PbIePU175Q
4 changed files with 11 additions and 6 deletions

View File

@ -5,6 +5,7 @@
set -x set -x
# If the latest commit cannot be verified, exit to error. # If the latest commit cannot be verified, exit to error.
echo "git config --global gpg.ssh.allowedSignersFile ~/src/codeberg.org/Aminda/ssh-allowed_signers/allowed_signers"
git verify-commit HEAD || exit 1 git verify-commit HEAD || exit 1
# Place my personal more questionable aliases in place, except that I don't # Place my personal more questionable aliases in place, except that I don't

View File

@ -6,6 +6,7 @@ set -x
# If my allowed_signers are present, use them, if not, clone them, and try # If my allowed_signers are present, use them, if not, clone them, and try
# again. The gitconfig expects them here. # again. The gitconfig expects them here.
if [ -d ~/src/gitea.blesmrt.net/Mikaela/ssh-allowed_signers ]; then if [ -d ~/src/gitea.blesmrt.net/Mikaela/ssh-allowed_signers ]; then
echo "git config --global gpg.ssh.allowedSignersFile ~/src/codeberg.org/Aminda/ssh-allowed_signers/allowed_signers"
git verify-commit HEAD || exit 1 git verify-commit HEAD || exit 1
sleep 3 sleep 3
else else
@ -13,6 +14,7 @@ else
# -vp - verbose, parent. This comment won't be repeated. # -vp - verbose, parent. This comment won't be repeated.
mkdir -vp ~/src/gitea.blesmrt.net/Mikaela/ mkdir -vp ~/src/gitea.blesmrt.net/Mikaela/
git clone https://gitea.blesmrt.net/Mikaela/ssh-allowed_signers.git ~/src/gitea.blesmrt.net/Mikaela/ssh-allowed_signers git clone https://gitea.blesmrt.net/Mikaela/ssh-allowed_signers.git ~/src/gitea.blesmrt.net/Mikaela/ssh-allowed_signers
echo "git config --global gpg.ssh.allowedSignersFile ~/src/codeberg.org/Aminda/ssh-allowed_signers/allowed_signers"
git verify-commit HEAD || exit 1 git verify-commit HEAD || exit 1
sleep 3 sleep 3
fi fi

View File

@ -747,9 +747,10 @@ function shell-things {
echo "shell-things: $SHELL_THINGS_REPO exists, git pulling..." echo "shell-things: $SHELL_THINGS_REPO exists, git pulling..."
echo "" echo ""
cd $SHELL_THINGS_REPO cd $SHELL_THINGS_REPO
git remote set-url origin https://gitea.blesmrt.net/Mikaela/shell-things.git git remote set-url origin https://codeberg.org/Aminda/shell-things.git
git fetch --all git fetch --all
git pull git pull
echo "git config --global gpg.ssh.allowedSignersFile ~/src/codeberg.org/Aminda/ssh-allowed_signers/allowed_signers"
git verify-commit HEAD || exit 1 git verify-commit HEAD || exit 1
sleep 10 sleep 10
echo "" echo ""
@ -760,7 +761,7 @@ function shell-things {
echo "" echo ""
echo "shell-things: $SHELL_THINGS_REPO doesn't exist, cloning..." echo "shell-things: $SHELL_THINGS_REPO doesn't exist, cloning..."
echo "" echo ""
git clone https://gitea.blesmrt.net/Mikaela/shell-things.git $SHELL_THINGS_REPO git clone https://codeberg.org/Aminda/shell-things.git $SHELL_THINGS_REPO
cd $SHELL_THINGS_REPO cd $SHELL_THINGS_REPO
sleep 10 sleep 10
echo "" echo ""
@ -903,7 +904,7 @@ myip6() {
# Easier verifying of SSH signed files: ssh-verify-file whatever@mikaela.info file.txt # Easier verifying of SSH signed files: ssh-verify-file whatever@mikaela.info file.txt
# It's assumed that signature of file.txt is called as file.txt.sig # It's assumed that signature of file.txt is called as file.txt.sig
sshAllowedSigners=$HOME/src/gitea.blesmrt.net/Mikaela/ssh-allowed_signers/allowed_signers sshAllowedSigners=$HOME/src/codeberg.org/Aminda/ssh-allowed_signers/allowed_signers
ssh-verify-file() { ssh-verify-file() {
echo "$1 ${2:?Usage: ssh-verify-file <email> <file-to-verify>}" > /dev/null echo "$1 ${2:?Usage: ssh-verify-file <email> <file-to-verify>}" > /dev/null
ssh-keygen -Y verify -f $sshAllowedSigners -I $1 -n file -s $2.sig < $2 ssh-keygen -Y verify -f $sshAllowedSigners -I $1 -n file -s $2.sig < $2

View File

@ -733,9 +733,10 @@ function shell-things {
echo "shell-things: $SHELL_THINGS_REPO exists, git pulling..." echo "shell-things: $SHELL_THINGS_REPO exists, git pulling..."
echo "" echo ""
cd $SHELL_THINGS_REPO cd $SHELL_THINGS_REPO
git remote set-url origin https://gitea.blesmrt.net/Mikaela/shell-things.git git remote set-url origin https://codeberg.org/Aminda/shell-things.git
git fetch --all git fetch --all
git pull git pull
echo "git config --global gpg.ssh.allowedSignersFile ~/src/codeberg.org/Aminda/ssh-allowed_signers/allowed_signers"
git verify-commit HEAD || exit 1 git verify-commit HEAD || exit 1
sleep 10 sleep 10
echo "" echo ""
@ -746,7 +747,7 @@ function shell-things {
echo "" echo ""
echo "shell-things: $SHELL_THINGS_REPO doesn't exist, cloning..." echo "shell-things: $SHELL_THINGS_REPO doesn't exist, cloning..."
echo "" echo ""
git clone https://gitea.blesmrt.net/Mikaela/shell-things.git $SHELL_THINGS_REPO git clone https://codeberg.org/Aminda/shell-things.git $SHELL_THINGS_REPO
cd $SHELL_THINGS_REPO cd $SHELL_THINGS_REPO
sleep 10 sleep 10
echo "" echo ""
@ -889,7 +890,7 @@ myip6() {
# Easier verifying of SSH signed files: ssh-verify-file whatever@mikaela.info file.txt # Easier verifying of SSH signed files: ssh-verify-file whatever@mikaela.info file.txt
# It's assumed that signature of file.txt is called as file.txt.sig # It's assumed that signature of file.txt is called as file.txt.sig
sshAllowedSigners=$HOME/src/gitea.blesmrt.net/Mikaela/ssh-allowed_signers/allowed_signers sshAllowedSigners=$HOME/src/codeberg.org/Aminda/ssh-allowed_signers/allowed_signers
ssh-verify-file() { ssh-verify-file() {
echo "$1 ${2:?Usage: ssh-verify-file <email> <file-to-verify>}" > /dev/null echo "$1 ${2:?Usage: ssh-verify-file <email> <file-to-verify>}" > /dev/null
ssh-keygen -Y verify -f $sshAllowedSigners -I $1 -n file -s $2.sig < $2 ssh-keygen -Y verify -f $sshAllowedSigners -I $1 -n file -s $2.sig < $2