This repository was archived by the owner on Aug 3, 2024. It is now read-only.
Foto değiştirildi #186
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: merge-test | |
on: | |
pull_request: | |
branches: | |
- master | |
jobs: | |
merge-markdown-lint: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-node@v3 | |
- name: Install markdownlint-cli | |
run: | | |
npm install | |
- name: Lint markdown files | |
run: | | |
npx -c 'markdownlint ./ --ignore ./vendor --ignore ./node_modules' | |
merge-jekyll-build: | |
runs-on: ubuntu-latest | |
env: | |
JEKYLL_ENV: production | |
strategy: | |
matrix: | |
python-version: ['3.10'] | |
ruby-version: ['2.7'] | |
steps: | |
- name: Checkout the repo | |
uses: actions/checkout@v3 | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v4 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Set up Ruby ${{ matrix.ruby-version }} | |
uses: ruby/setup-ruby@v1 | |
with: | |
ruby-version: ${{ matrix.ruby-version }} | |
bundler-cache: true | |
- name: Upgrade pip | |
run: | | |
python -m pip install --upgrade pip | |
- name: Install pipenv | |
run: | | |
python -m pip install pipenv | |
# no need to install bundle with bundler-cache: true | |
# - name: Install Ruby dependencies | |
# run: | | |
# bundle update | |
# See: https://github.com/actions/cache/blob/main/examples.md#python---pipenv | |
# - name: Cache Pipfile files if possible | |
# uses: actions/[email protected] | |
# with: | |
# path: ~/.local/share/virtualenvs | |
# key: ${{ runner.os }}-pipenv-${{ hashFiles('Pipfile.lock') }} | |
# restore-keys: | | |
# ${{ runner.os }}-pipenv-${{ hashFiles('Pipfile.lock') }} | |
- name: Install Python dependencies | |
run: | | |
pipenv install | |
- name: Build the site | |
run: | | |
bundle exec jekyll build --config _config.yml,_config-deploy.yml,_config-merge.yml | |
- name: Test (HTMLProofer) | |
run: | | |
bundle exec htmlproofer ./_site --disable-external --allow-hash-href --alt-ignore "/.*/" | |
- name: Test (pytest) | |
run: | | |
pipenv run python test.py pytest | |
- name: Deploy (Dry-Run) | |
uses: JamesIves/[email protected] | |
with: | |
dry-run: true | |
token: ${{ secrets.GITHUB_TOKEN }} | |
branch: gh-pages # The branch the action should deploy to. | |
folder: _site # The folder the action should deploy. | |
clean: true # Automatically remove deleted files from the deploy branch | |
single-commit: true # Like push force, keep only the last commit | |
git-config-name: #use username that pushes to master | |
git-config-email: <> #[email protected] |