2021-06-01 13:11:48 +02:00
|
|
|
name: Theme Validation and deployment
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- develop
|
|
|
|
- master
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
build:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
|
|
|
|
|
|
|
- name: Clone deployment repo
|
2021-06-01 14:06:12 +02:00
|
|
|
env:
|
|
|
|
DEPLOY_KEY: ${{ secrets.DEPLOY_KEY }}
|
2021-06-01 13:11:48 +02:00
|
|
|
run: |
|
|
|
|
echo "Cloning destination repo"
|
2021-06-01 14:03:35 +02:00
|
|
|
git config --global user.email "pietervdvn@posteo.net"
|
2021-06-01 13:11:48 +02:00
|
|
|
git config --global user.name "MapComplete"
|
2021-06-01 13:53:08 +02:00
|
|
|
git clone --single-branch --branch main "https://x-access-token:$DEPLOY_KEY@github.com/MapComplete/mapcomplete.github.io.git"
|
2021-06-01 13:11:48 +02:00
|
|
|
echo "Destination repo is cloned"
|
2021-06-01 13:26:51 +02:00
|
|
|
|
|
|
|
- name: "Copying files"
|
|
|
|
run: |
|
|
|
|
echo "Deploying"
|
2021-06-01 13:43:09 +02:00
|
|
|
# rm -rf mapcomplete.github.io/*
|
|
|
|
# cp dist/* mapcomplete.github.io/
|
|
|
|
cd mapcomplete.github.io/
|
2021-06-01 13:35:31 +02:00
|
|
|
echo "mapcomplete.osm.be" > CNAME
|
2021-06-01 13:43:09 +02:00
|
|
|
echo "Test" > test
|
2021-06-01 13:46:04 +02:00
|
|
|
git add *
|
2021-06-01 13:26:51 +02:00
|
|
|
git commit -am "Deploying a new version"
|
|
|
|
git push
|