diff options
Diffstat (limited to '.gitea/workflows/git-sync.yaml')
| -rw-r--r-- | .gitea/workflows/git-sync.yaml | 36 |
1 files changed, 34 insertions, 2 deletions
diff --git a/.gitea/workflows/git-sync.yaml b/.gitea/workflows/git-sync.yaml index 7ad4e72..561f3b4 100644 --- a/.gitea/workflows/git-sync.yaml +++ b/.gitea/workflows/git-sync.yaml @@ -3,13 +3,45 @@ name: git-sync-with-mirror on: push: branches: [ master ] + pull_request: + branches: [ master ] workflow_dispatch: jobs: + test: + runs-on: ubuntu-latest + timeout-minutes: 10 + + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Install Emacs + run: | + sudo apt-get update + sudo apt-get install -y emacs-nox + + - name: Setup environment + run: | + cp .env.example .env + + - name: Load configuration + run: | + emacs --batch -l init.el + + - name: Byte compile configuration + run: | + emacs --batch -f batch-byte-compile init.el modules/*.el + git-sync: runs-on: ubuntu-latest + needs: test + timeout-minutes: 15 steps: + - name: Checkout + uses: actions/checkout@v4 + - name: git-sync env: git_sync_source_repo: git@git.fridu.us:heckyel/emacs-personal.git @@ -19,8 +51,8 @@ jobs: with: source_repo: git@git.fridu.us:heckyel/emacs-personal.git source_branch: "master" - destination_repo: ssh://git@c.fridu.us/software/emacs-personal.git destination_branch: "master" + destination_repo: ssh://git@c.fridu.us/software/emacs-personal.git source_ssh_private_key: ${{ secrets.GIT_SYNC_SOURCE_SSH_PRIVATE_KEY }} destination_ssh_private_key: ${{ secrets.GIT_SYNC_DESTINATION_SSH_PRIVATE_KEY }} @@ -33,7 +65,7 @@ jobs: with: source_repo: git@git.fridu.us:heckyel/emacs-personal.git source_branch: "master" - destination_repo: git@git.sr.ht:~heckyel/emacs-personal destination_branch: "master" + destination_repo: git@git.sr.ht:~heckyel/emacs-personal source_ssh_private_key: ${{ secrets.GIT_SYNC_SOURCE_SSH_PRIVATE_KEY }} destination_ssh_private_key: ${{ secrets.GIT_SYNC_DESTINATION_SSH_PRIVATE_KEY }} |
