diff --git a/.github/workflows/black.yml b/.github/workflows/black.yml index 323d9446a..7aa3895bd 100644 --- a/.github/workflows/black.yml +++ b/.github/workflows/black.yml @@ -1,17 +1,21 @@ +--- name: Black on: - pull_request: push: - branches: - - main + pull_request: + branches: [main, master] jobs: - lint: + black: + name: Black runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 - - uses: psf/black@stable + - name: Checkout Code + uses: actions/checkout@v3 + + - name: Run Black + uses: psf/black@stable with: options: '--exclude="docs/01python/07for/_samples/sum_1to100.ipynb"' jupyter: true diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index e2f15f420..97846de43 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -1,19 +1,23 @@ +--- name: Build and Deploy + on: push: - branches: - - main + branches: main + permissions: contents: write + jobs: build-and-deploy: - concurrency: ci-${{ github.ref }} # Recommended if you intend to make multiple deployments in quick succession. + name: Build and Deploy + concurrency: ci-${{ github.ref }} runs-on: ubuntu-latest steps: - - name: Checkout 🛎️ + - name: Checkout Code uses: actions/checkout@v3 - - name: Install and Build 🔧 # This example project is built using npm and outputs the result to the 'build' folder. Replace with the commands required to build your project, or remove this step entirely if your site is pre-built. + - name: Install and Build 🔧 run: | npm ci npm run build @@ -22,4 +26,4 @@ jobs: uses: JamesIves/github-pages-deploy-action@v4 with: clean-exclude: pr-preview/ - folder: build # The folder the action should deploy. + folder: build diff --git a/.github/workflows/eslint.yml b/.github/workflows/eslint.yml index de176c182..784d3e380 100644 --- a/.github/workflows/eslint.yml +++ b/.github/workflows/eslint.yml @@ -1,15 +1,21 @@ +--- name: ESLint + on: - pull_request: push: - branches: - - main + pull_request: + branches: [main, master] + jobs: - build: + eslint: + name: ESLint runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - name: Checkout Code + uses: actions/checkout@v3 + - name: Install modules run: npm ci + - name: Run ESLint run: npx eslint . --ext .js,.jsx,.ts,.tsx diff --git a/.github/workflows/linter.yml b/.github/workflows/linter.yml deleted file mode 100644 index 8fa5f8d29..000000000 --- a/.github/workflows/linter.yml +++ /dev/null @@ -1,49 +0,0 @@ ---- -################################# -################################# -## Super Linter GitHub Actions ## -################################# -################################# -name: Lint Code Base - -############################# -# Start the job on all push # -############################# -on: - push: - pull_request: - branches: [master, main] - -############### -# Set the Job # -############### -jobs: - build: - # Name the Job - name: Lint Code Base - # Set the agent to run on - runs-on: ubuntu-latest - - ################## - # Load all steps # - ################## - steps: - ########################## - # Checkout the code base # - ########################## - - name: Checkout Code - uses: actions/checkout@v3 - with: - # Full git history is needed to get a proper - # list of changed files within `super-linter` - fetch-depth: 0 - - ################################ - # Run Linter against code base # - ################################ - - name: Lint Code Base - uses: github/super-linter@v4 - env: - VALIDATE_ALL_CODEBASE: false - DEFAULT_BRANCH: main - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/prettier.yml b/.github/workflows/prettier.yml index adbb2cd04..46feabf38 100644 --- a/.github/workflows/prettier.yml +++ b/.github/workflows/prettier.yml @@ -1,25 +1,22 @@ +--- name: Prettier -# This action works with pull requests and pushes on: - pull_request: push: - branches: - - main + pull_request: + branches: [master, main] jobs: prettier: + name: Prettier runs-on: ubuntu-latest - steps: - - name: Checkout - uses: actions/checkout@v2 + - name: Checkout Code + uses: actions/checkout@v3 with: - # Make sure the actual branch is checked out when running on pull requests ref: ${{ github.head_ref }} - - name: Prettify code + - name: Run Prettier uses: creyD/prettier_action@v4.2 with: - # This part is also where you can pass other options, for example: prettier_options: --write . diff --git a/.github/workflows/preview.yml b/.github/workflows/preview.yml index 99b41e2b1..9757a3e2e 100644 --- a/.github/workflows/preview.yml +++ b/.github/workflows/preview.yml @@ -1,3 +1,4 @@ +--- name: Deploy PR previews on: @@ -12,10 +13,11 @@ concurrency: preview-${{ github.ref }} jobs: deploy-preview: - runs-on: ubuntu-20.04 + name: Deploy PR previews + runs-on: ubuntu-latest steps: - - name: Checkout - uses: actions/checkout@v2 + - name: Checkout Code + uses: actions/checkout@v3 - name: Install and Build run: | diff --git a/.github/workflows/super_linter.yml b/.github/workflows/super_linter.yml new file mode 100644 index 000000000..0766f335f --- /dev/null +++ b/.github/workflows/super_linter.yml @@ -0,0 +1,24 @@ +--- +name: Super Linter + +on: + push: + pull_request: + branches: [master, main] + +jobs: + super-linter: + name: Super Linter + runs-on: ubuntu-latest + steps: + - name: Checkout Code + uses: actions/checkout@v3 + with: + fetch-depth: 0 + + - name: Run Super Linter + uses: github/super-linter@v4 + env: + VALIDATE_ALL_CODEBASE: false + DEFAULT_BRANCH: main + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/docs/03extras/04website/02docusaurus/index.mdx b/docs/03extras/04website/02docusaurus/index.mdx index e25fff602..2ae44e710 100644 --- a/docs/03extras/04website/02docusaurus/index.mdx +++ b/docs/03extras/04website/02docusaurus/index.mdx @@ -176,7 +176,7 @@ import LifeGame from "@site/src/components/LifeGame/LifeGame"; ::: :::tip -Docusaurus で数式を表示するには、以下のようにします。(2022年12月時点)[Docusaurus の公式サイトの説明](https://docusaurus.io/docs/markdown-features/math-equations)を参考にしてください。 +Docusaurus で数式を表示するには、以下のようにします。(2022 年 12 月時点)[Docusaurus の公式サイトの説明](https://docusaurus.io/docs/markdown-features/math-equations)を参考にしてください。 1. ターミナルで以下を実行して、プラグインをインストールします。