Skip to content

Commit 0ea58f6

Browse files
authored
CIをアップデート (#268)
1 parent 29ae96c commit 0ea58f6

File tree

213 files changed

+6317
-8917
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

213 files changed

+6317
-8917
lines changed

.eslintignore

Lines changed: 0 additions & 1 deletion
This file was deleted.

.eslintrc.json

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

.github/actions/build/action.yml

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

.github/actions/execute-notebooks/action.yml

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

.github/actions/install-node-packages/action.yml

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

.github/actions/install-python-modules/action.yml

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

.github/workflows/build-test.yml

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

.github/workflows/ci.yml

Lines changed: 126 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,126 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
pull_request:
8+
9+
jobs:
10+
build:
11+
name: Build
12+
runs-on: ubuntu-latest
13+
steps:
14+
- name: Checkout Code
15+
uses: actions/checkout@v5
16+
17+
- name: Setup Node.js
18+
uses: actions/setup-node@v4
19+
with:
20+
node-version-file: .nvmrc
21+
cache: npm
22+
23+
- name: Install Packages
24+
run: npm ci
25+
shell: bash
26+
27+
- name: Build
28+
run: npm run build
29+
shell: bash
30+
31+
prettier:
32+
name: Prettier
33+
runs-on: ubuntu-latest
34+
steps:
35+
- name: Checkout Code
36+
uses: actions/checkout@v5
37+
38+
- name: Setup Node.js
39+
uses: actions/setup-node@v4
40+
with:
41+
node-version-file: .nvmrc
42+
cache: npm
43+
44+
- name: Install Packages
45+
run: npm ci
46+
shell: bash
47+
48+
- name: Format
49+
run: npx prettier --check .
50+
shell: bash
51+
52+
black:
53+
name: Black
54+
runs-on: ubuntu-latest
55+
steps:
56+
- name: Checkout Code
57+
uses: actions/checkout@v5
58+
59+
- name: Setup Poetry
60+
run: pipx install poetry==2.0.0
61+
shell: bash
62+
63+
- name: Install Poetry Packages
64+
run: poetry install --no-root
65+
shell: bash
66+
67+
- name: Run Black
68+
run: poetry run black --check .
69+
70+
notebooks:
71+
name: Notebooks
72+
runs-on: ubuntu-latest
73+
steps:
74+
- name: Checkout Code
75+
uses: actions/checkout@v5
76+
77+
- name: Setup Poetry
78+
run: pipx install poetry==2.0.0
79+
shell: bash
80+
81+
- name: Install Poetry Packages
82+
run: poetry install --no-root
83+
shell: bash
84+
85+
- name: Execute Notebooks
86+
run: |
87+
poetry run jupyter nbconvert --inplace --to notebook --execute --allow-errors static/**/*.ipynb
88+
poetry run databooks meta --rm-outs --rm-exec --yes .
89+
git diff --exit-code
90+
shell: bash
91+
92+
isort:
93+
name: isort
94+
runs-on: ubuntu-latest
95+
steps:
96+
- name: Checkout Code
97+
uses: actions/checkout@v5
98+
99+
- name: Setup Poetry
100+
run: pipx install poetry==2.0.0
101+
shell: bash
102+
103+
- name: Install Poetry Packages
104+
run: poetry install --no-root
105+
shell: bash
106+
107+
- name: Run nqQA isort
108+
run: poetry run nbqa isort --nbqa-diff .
109+
110+
pyupgrade:
111+
name: pyupgrade
112+
runs-on: ubuntu-latest
113+
steps:
114+
- name: Checkout Code
115+
uses: actions/checkout@v5
116+
117+
- name: Setup Poetry
118+
run: pipx install poetry==2.0.0
119+
shell: bash
120+
121+
- name: Install Poetry Packages
122+
run: poetry install --no-root
123+
shell: bash
124+
125+
- name: Run nqQA pyupgrade
126+
run: poetry run nbqa pyupgrade --nbqa-diff .

.github/workflows/deploy.yml

Lines changed: 17 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
1-
name: Build and Deploy
1+
name: Deploy
22

33
on:
44
push:
5-
branches: [main, master]
5+
branches:
6+
- main
67

78
permissions:
89
contents: read
@@ -19,20 +20,26 @@ jobs:
1920
runs-on: ubuntu-latest
2021
steps:
2122
- name: Checkout Code
22-
uses: actions/checkout@v3
23+
uses: actions/checkout@v5
2324
with:
2425
fetch-depth: 0
2526

26-
- name: Execute Notebooks
27-
uses: ./.github/actions/execute-notebooks
27+
- name: Setup Node.js
28+
uses: actions/setup-node@v4
29+
with:
30+
node-version-file: .nvmrc
31+
cache: npm
32+
33+
- name: Install Packages
34+
run: npm ci
35+
shell: bash
2836

2937
- name: Build
30-
uses: ./.github/actions/build
31-
with:
32-
base-url: /
38+
run: npm run build
39+
shell: bash
3340

3441
- name: Upload artifact
35-
uses: actions/upload-pages-artifact@v1
42+
uses: actions/upload-pages-artifact@v4
3643
with:
3744
path: build
3845

@@ -45,4 +52,4 @@ jobs:
4552
steps:
4653
- name: Deploy to GitHub Pages
4754
id: deployment
48-
uses: actions/deploy-pages@v2
55+
uses: actions/deploy-pages@v4

.github/workflows/formatter.yml

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

0 commit comments

Comments
 (0)