Skip to content

Commit 39bdd73

Browse files
authored
Merge pull request #38 from jepler/readthedocs-v2
Add "v2" readthedocs setup & modernize CI
2 parents e1fe886 + 63f2c98 commit 39bdd73

File tree

8 files changed

+81
-139
lines changed

8 files changed

+81
-139
lines changed

.github/workflows/build.yml

Lines changed: 4 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -8,52 +8,9 @@ on: [pull_request, push]
88

99
jobs:
1010
test:
11-
runs-on: ubuntu-20.04
11+
runs-on: ubuntu-latest
1212
steps:
13-
- name: View context attributes
14-
uses: actions/github-script@v6
13+
- name: Run Build CI workflow
14+
uses: adafruit/workflows-circuitpython-libs/build@main
1515
with:
16-
script: console.log(JSON.stringify(context, null, 2))
17-
- name: Translate Repo Name For Build Tools filename_prefix
18-
id: repo-name
19-
run: |
20-
echo ::set-output name=repo-name::$(
21-
echo ${{ github.repository }} |
22-
awk -F '\/' '{ print tolower($2) }' |
23-
tr '_' '-'
24-
)
25-
- name: Set up Python 3.x
26-
uses: actions/setup-python@v1
27-
with:
28-
python-version: 3.x
29-
- name: Versions
30-
run: |
31-
python3 --version
32-
- name: Checkout Current Repo
33-
uses: actions/checkout@v1
34-
with:
35-
submodules: true
36-
- name: Checkout tools repo
37-
uses: actions/checkout@v2
38-
with:
39-
repository: adafruit/actions-ci-circuitpython-libs
40-
path: actions-ci
41-
- name: Install dependencies
42-
# (e.g. - apt-get: gettext, etc; pip: circuitpython-build-tools, requirements.txt; etc.)
43-
run: |
44-
source actions-ci/install.sh
45-
- name: Library version
46-
run: git describe --dirty --always --tags
47-
- name: Perform build & test
48-
run: |
49-
./build.sh
50-
- name: Archive bundles
51-
uses: actions/upload-artifact@v2
52-
with:
53-
name: bundles
54-
path: ${{ github.workspace }}/bundles/
55-
- name: Archive docs
56-
uses: actions/upload-artifact@v2
57-
with:
58-
name: docs
59-
path: ${{ github.workspace }}/_build/html
16+
package-prefix: jepler_udecimal
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# SPDX-FileCopyrightText: 2021 Scott Shawcroft for Adafruit Industries
2+
#
3+
# SPDX-License-Identifier: MIT
4+
5+
name: Failure help text
6+
7+
on:
8+
workflow_run:
9+
workflows: ["Build CI"]
10+
types:
11+
- completed
12+
13+
jobs:
14+
post-help:
15+
runs-on: ubuntu-latest
16+
if: ${{ github.event.workflow_run.conclusion == 'failure' && github.event.workflow_run.event == 'pull_request' }}
17+
steps:
18+
- name: Post comment to help
19+
uses: adafruit/circuitpython-action-library-ci-failed@v1

.github/workflows/release.yml

Lines changed: 0 additions & 85 deletions
This file was deleted.

.github/workflows/release_gh.yml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# SPDX-FileCopyrightText: 2017 Scott Shawcroft, written for Adafruit Industries
2+
#
3+
# SPDX-License-Identifier: MIT
4+
5+
name: GitHub Release Actions
6+
7+
on:
8+
release:
9+
types: [published]
10+
11+
jobs:
12+
upload-release-assets:
13+
runs-on: ubuntu-latest
14+
steps:
15+
- name: Run GitHub Release CI workflow
16+
uses: adafruit/workflows-circuitpython-libs/release-gh@main
17+
with:
18+
github-token: ${{ secrets.GITHUB_TOKEN }}
19+
upload-url: ${{ github.event.release.upload_url }}
20+
package-prefix: jepler_udecimal

.github/workflows/release_pypi.yml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# SPDX-FileCopyrightText: 2017 Scott Shawcroft, written for Adafruit Industries
2+
#
3+
# SPDX-License-Identifier: MIT
4+
5+
name: PyPI Release Actions
6+
7+
on:
8+
release:
9+
types: [published]
10+
11+
jobs:
12+
upload-release-assets:
13+
runs-on: ubuntu-latest
14+
steps:
15+
- name: Run PyPI Release CI workflow
16+
uses: adafruit/workflows-circuitpython-libs/release-pypi@main
17+
with:
18+
pypi-username: ${{ secrets.pypi_username }}
19+
pypi-password: ${{ secrets.pypi_password }}

.readthedocs.yaml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# SPDX-FileCopyrightText: 2021 ladyada for Adafruit Industries
2+
#
3+
# SPDX-License-Identifier: Unlicense
4+
5+
# Read the Docs configuration file
6+
# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details
7+
8+
# Required
9+
version: 2
10+
11+
build:
12+
os: ubuntu-20.04
13+
tools:
14+
python: "3"
15+
16+
python:
17+
install:
18+
- requirements: docs/requirements.txt
19+
- requirements: requirements.txt

.readthedocs.yml

Lines changed: 0 additions & 7 deletions
This file was deleted.

0 commit comments

Comments
 (0)