Skip to content

Commit

Permalink
Update deploy.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
LoickCh authored Oct 8, 2024
1 parent 552723b commit 7533976
Showing 1 changed file with 5 additions and 14 deletions.
19 changes: 5 additions & 14 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,22 +15,13 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
uses: actions/checkout@v3 # Updated to use v3

- name: Setup Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: '3.0.2'

# Temporarily comment out caching for debugging
# - name: Enable bundler cache
# uses: actions/cache@v2
# with:
# path: vendor/bundle
# key: ${{ runner.os }}-gems-${{ hashFiles('**/Gemfile.lock') }}
# restore-keys: |
# ${{ runner.os }}-gems-

- name: Install deps
run: |
gem install bundler
Expand All @@ -43,10 +34,10 @@ jobs:
run: |
git config --global user.name "GitHub Action"
git config --global user.email "41898282+github-actions[bot]@users.noreply.github.com"
if [[ ${GITHUB_REF} = refs/pull/*/merge ]]; then # pull request
if [[ ${GITHUB_REF} = refs/pull/*/merge ]]; then
echo "SRC_BRANCH=${GITHUB_HEAD_REF}" >> $GITHUB_ENV
echo "NO_PUSH=--no-push" >> $GITHUB_ENV
elif [[ ${GITHUB_REF} = refs/heads/* ]]; then # branch, e.g. master, source etc
elif [[ ${GITHUB_REF} = refs/heads/* ]]; then
echo "SRC_BRANCH=${GITHUB_REF#refs/heads/}" >> $GITHUB_ENV
fi
echo "DEPLOY_BRANCH=gh-pages" >> $GITHUB_ENV
Expand All @@ -60,4 +51,4 @@ jobs:
- name: Deploy website
run: yes | bash bin/deploy --verbose ${{ env.NO_PUSH }} \
--src ${{ env.SRC_BRANCH }} \
--deploy ${{ env.DEPLOY_BRANCH }}
--deploy ${{ env.DEPLOY_BRANCH }}

0 comments on commit 7533976

Please sign in to comment.