Skip to content

Merge branch 'main' of github.com:jcuenod/parabible-deno-server #40

Merge branch 'main' of github.com:jcuenod/parabible-deno-server

Merge branch 'main' of github.com:jcuenod/parabible-deno-server #40

Workflow file for this run

# This is a basic workflow to help you get started with Actions
name: Push to Gitlab
# Controls when the workflow will run
on:
# Triggers the workflow on push or pull request events but only for the master branch
push:
branches:
- main
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
# This workflow contains a single job called "build"
mirror:
# The type of runner that the job will run on
runs-on: ubuntu-latest
# Steps represent a sequence of tasks that will be executed as part of the job
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v3
- name: Unshallow current repo (for push)
run: |
git fetch --unshallow origin refs/heads/${{ github.ref_name }}:refs/remotes/origin/${{ github.ref_name }}
- name: Set up credentials for mirror
run: |
echo "echo ${{ secrets.PERSONAL_ACCESS_TOKEN }}" > $HOME/.git-askpass
chmod 755 $HOME/.git-askpass
git config --global core.askPass $HOME/.git-askpass
git config --global credential.helper cache
- name: Add remote mirror
run: |
git remote add mirror https://${{ secrets.PERSONAL_ACCESS_TOKEN }}@${{ secrets.HTTPS_PUSH_URL }}
- name: Pushing to branch
run: |
git push mirror ${{ github.ref_name }}