Skip to content

Commit

Permalink
feat: 工作流更新 (#130)
Browse files Browse the repository at this point in the history
* ci: 合并构建与发布的工作流

* chore: 更新yarn版本

* chore: 更新yarn.lock

* chore: 禁用turbo追踪

* fix: 移除turbo.json中的多余参数

* ci: 升级node版本
  • Loading branch information
SherkeyXD authored Feb 12, 2024
1 parent 1e5c91f commit f21a9d4
Show file tree
Hide file tree
Showing 8 changed files with 5,970 additions and 9,271 deletions.
Original file line number Diff line number Diff line change
@@ -1,21 +1,29 @@
name: azure-deploy
name: Build and Deploy

on:
push:
branches:
- main
pull_request:
types: [opened, synchronize, reopened, closed]
workflow_dispatch:
inputs:
deploy-to-azure:
description: '部署到Azure'
default: true
required: true
type: boolean

jobs:
deploy:
timeout-minutes: 20
runs-on: ubuntu-latest
env:
DO_NOT_TRACK: 1
steps:
- name: Check out code
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Fetch docs
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
repository: "MaaAssistantArknights/MaaAssistantArknights"
sparse-checkout: "docs"
Expand All @@ -29,9 +37,9 @@ jobs:
rm -r ./temp
- name: Setup Node.js environment
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: 18
node-version: 20
cache: "yarn"

- name: Install dependencies
Expand All @@ -40,8 +48,9 @@ jobs:
- name: Build
run: yarn build

- name: Deploy
- name: Deploy to Azure
id: deploy
if: github.repository == 'MaaAssistantArknights/maa-website' && ((github.event_name == 'push' && github.ref == 'refs/heads/main') || (github.event_name == 'workflow_dispatch' && github.event.inputs.deploy-to-azure == 'true'))
uses: Azure/static-web-apps-deploy@v1
with:
azure_static_web_apps_api_token: ${{ secrets.AZURE_STATIC_WEB_APPS_API_TOKEN_KIND_WAVE_001CBA500 }}
Expand Down
44 changes: 0 additions & 44 deletions .github/workflows/build-test.yaml

This file was deleted.

874 changes: 0 additions & 874 deletions .yarn/releases/yarn-3.6.3.cjs

This file was deleted.

893 changes: 893 additions & 0 deletions .yarn/releases/yarn-4.1.0.cjs

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion .yarnrc.yml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
nodeLinker: node-modules
yarnPath: .yarn/releases/yarn-3.6.3.cjs
yarnPath: .yarn/releases/yarn-4.1.0.cjs
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,5 +28,5 @@
"framer-motion": "^10.2.3",
"react-use": "^17.4.0"
},
"packageManager": "yarn@3.6.3"
"packageManager": "yarn@4.1.0"
}
1 change: 0 additions & 1 deletion turbo.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
{
"$schema": "https://turborepo.org/schema.json",
"baseBranch": "origin/main",
"pipeline": {
"build": {
"dependsOn": [
Expand Down
Loading

0 comments on commit f21a9d4

Please sign in to comment.