-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
4 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12,8 +12,8 @@ trap 'handle_error $LINENO' ERR | |
|
||
# Set up Arch Linux environment | ||
setup_environment() { | ||
export REPO="https://$(git config --get remote.origin.url | sed -E 's|.+[:/]([^:/]+)/([^/.]+)(\.git)?|\1|').github.io/repo/x86_64" | ||
echo -e "\n[StratOS]\nSigLevel = Optional TrustAll\nServer = $URL" | sudo tee -a /etc/pacman.conf | ||
export URL="https://$(git config --get remote.origin.url | sed -E 's|.+[:/]([^:/]+)/([^/.]+)(\.git)?|\1|').github.io/repo/x86_64" | ||
echo -e "\n[StratOS-repo]\nSigLevel = Optional TrustAll\nServer = $URL" | sudo tee -a /etc/pacman.conf | ||
sudo sed -i 's/purge debug/purge !debug/g' /etc/makepkg.conf | ||
sudo sed -i 's/^#* *GPGKEY *=.*/GPGKEY="19A421C3D15C8B7C672F0FACC4B8A73AB86B9411"/' /etc/makepkg.conf # add zstg's public key | ||
sed -i 's/^#*\(PACKAGER=\).*/\1"StratOS team <[email protected]>"/' /etc/makepkg.conf | ||
|
@@ -138,15 +138,15 @@ build_and_package() { | |
|
||
# Initialize and push to GitHub | ||
initialize_and_push() { | ||
export REPO="$(git config --get remote.origin.url | sed -E 's|.+[:/]([^:/]+)/([^/.]+)(\.git)?|\1/\2|')" | ||
export URL="$(git config --get remote.origin.url | sed -E 's|.+[:/]([^:/]+)/([^/.]+)(\.git)?|\1|')" | ||
cd "$dir" | ||
bash ./initialize.sh | ||
sudo git config --global user.name 'github-actions[bot]' | ||
sudo git config --global user.email 'github-actions[bot]@users.noreply.github.com' | ||
sudo git add . | ||
sudo git commit -am "Update packages" | ||
sudo git pull | ||
sudo git push "https://x-access-token:${GITHUB_TOKEN}@github.com/$REPO" --force | ||
sudo git push "https://x-access-token:${GITHUB_TOKEN}@github.com/$URL/repo" --force | ||
} | ||
|
||
# Main function | ||
|