circuitpython/.github/workflows/create_website_pr.yml
Jeff Epler 23022a5a7f
Add, use tools/describe script
This isn't intended to make any overt behavioral change, but
there is a slight one in the value of CP_VERSION that will be used
during CI, because it will now include `--always --match "..."`,
so there could be a change to the uploaded name of the mpy-cross
artifacts on s3.
2022-01-04 11:14:03 -06:00

47 lines
1.4 KiB
YAML

# SPDX-FileCopyrightText: 2014 MicroPython & CircuitPython contributors (https://github.com/adafruit/circuitpython/graphs/contributors)
#
# SPDX-License-Identifier: MIT
name: Update CircuitPython.org
on:
release:
types: [published]
jobs:
website:
runs-on: ubuntu-20.04
steps:
- name: Dump GitHub context
env:
GITHUB_CONTEXT: ${{ toJson(github) }}
run: echo "$GITHUB_CONTEXT"
- uses: actions/checkout@v2.2.0
with:
submodules: false
fetch-depth: 1
- name: Set up Python 3
uses: actions/setup-python@v2
with:
python-version: "3.x"
- name: Get CP deps
run: python tools/ci_fetch_deps.py website ${{ github.sha }}
- name: Install deps
run: |
pip install -r requirements-dev.txt
- name: Versions
run: |
gcc --version
python3 --version
- name: CircuitPython version
run: |
tools/describe || git log --parents HEAD~4..
echo >>$GITHUB_ENV CP_VERSION=$(tools/describe)
- name: Website
run: python3 build_board_info.py
working-directory: tools
env:
RELEASE_TAG: ${{ github.event.release.tag_name }}
ADABOT_GITHUB_ACCESS_TOKEN: ${{ secrets.BLINKA_GITHUB_ACCESS_TOKEN }}
if: github.event_name == 'release' && (github.event.action == 'published' || github.event.action == 'rerequested')