Skip to content
This repository has been archived by the owner on Dec 5, 2022. It is now read-only.

deployment overwrites my master branch with the build #27

Open
sycom opened this issue Nov 28, 2019 · 0 comments
Open

deployment overwrites my master branch with the build #27

sycom opened this issue Nov 28, 2019 · 0 comments

Comments

@sycom
Copy link

sycom commented Nov 28, 2019

Sorry for coming with such a specific problem, but I'm trying to use the script for deploying a mkdocs website.

For some reason, the result is a brand new commit on master that totally overwrites the repo.

Does anyone have an idea of what happens here?

My .yml :

name: Publication

on:
  push:
    branches:
    - master
jobs:
  build:
    runs-on: ubuntu-latest
    steps:
    - name: Checkout on Current Commit
      uses: actions/checkout@master
    - name: Setup python
      uses: actions/setup-python@v1
      with:
        python-version: '3.x'
        architecture: 'x64'
    - name: Install requirements
      run: python -m pip install -r py-requirements.txt
    - name: Build with mkdocs
      run: python -m mkdocs build --clean
    - name: Say that this is not Jekyll
      run: cat > site/.nojekyll
    - name: Publish site
      uses: maxheld83/[email protected]
      env:
        BUILD_DIR: "site/"
        GH_PAT: ${{ secrets.GH_PAT }}

Full code can be seen on gitlab (not on github since repo is reinitialized with each deploy ;-) :
https://gitlab.com/know-rmandie/know-rmandie.gitlab.io/blob/master/.github/workflows/mkdocs.yml

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant