2023-07-26 17:49:17 +00:00
|
|
|
#!/usr/bin/env bash
|
|
|
|
set -euo pipefail
|
|
|
|
|
|
|
|
# prevent these variables from being unset by writePureShellScript
|
2023-07-28 11:25:30 +00:00
|
|
|
export KEEP_VARS="GIT_AUTHOR_NAME GIT_AUTHOR_EMAIL GIT_COMMITTER_NAME GIT_COMMITTER_EMAIL PR_TITLE REMOTE_BRANCH REPO REPO_DIR${KEEP_VARS:+ $KEEP_VARS}"
|
2023-07-26 17:49:17 +00:00
|
|
|
|
|
|
|
# configure variables for actions
|
|
|
|
export PR_TITLE="Automatic flake update - $(date --iso-8601=minutes)"
|
|
|
|
export REMOTE_BRANCH="flake-update-$(date --iso-8601)"
|
2023-07-28 11:25:30 +00:00
|
|
|
export REPO="gitea@git.clan.lol:clan/clan-infra.git"
|
2023-07-26 17:49:17 +00:00
|
|
|
export REPO_DIR=$TMPDIR/repo
|
2023-07-28 11:25:30 +00:00
|
|
|
export GIT_AUTHOR_NAME="Clan Merge Bot"
|
|
|
|
export GIT_AUTHOR_EMAIL="clan-bot@git.clan.lol"
|
|
|
|
export GIT_COMMITTER_NAME="$GIT_AUTHOR_NAME"
|
|
|
|
export GIT_COMMITTER_EMAIL="$GIT_AUTHOR_NAME"
|
2023-07-26 17:49:17 +00:00
|
|
|
|
|
|
|
action-checkout
|
|
|
|
cd $REPO_DIR
|
2023-07-28 11:25:30 +00:00
|
|
|
action-ensure-tea-login
|
2023-07-26 17:49:17 +00:00
|
|
|
action-flake-update
|
2023-07-28 11:25:30 +00:00
|
|
|
action-create-pr --assignees clan-bot
|