mirror of
https://github.com/mermaid-js/mermaid.git
synced 2025-08-26 11:46:42 +02:00
Merge branches 'develop' and 'develop' of https://github.com/mermaid-js/mermaid into develop
* 'develop' of https://github.com/mermaid-js/mermaid: chore: Merge checks into lint chore: Remove unnecessary workflows chore: Add concurrency for actions chore: Skip running E2E on Push to most branches * 'develop' of https://github.com/mermaid-js/mermaid: chore: Merge checks into lint chore: Remove unnecessary workflows chore: Add concurrency for actions chore: Skip running E2E on Push to most branches
This commit is contained in:
2
.github/workflows/autofix.yml
vendored
2
.github/workflows/autofix.yml
vendored
@@ -7,6 +7,8 @@ on:
|
|||||||
permissions:
|
permissions:
|
||||||
contents: read
|
contents: read
|
||||||
|
|
||||||
|
concurrency: ${{ github.workflow }}-${{ github.ref }}
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
autofix:
|
autofix:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
2
.github/workflows/build-docs.yml
vendored
2
.github/workflows/build-docs.yml
vendored
@@ -8,6 +8,8 @@ on:
|
|||||||
pull_request:
|
pull_request:
|
||||||
merge_group:
|
merge_group:
|
||||||
|
|
||||||
|
concurrency: ${{ github.workflow }}-${{ github.ref }}
|
||||||
|
|
||||||
permissions:
|
permissions:
|
||||||
contents: read
|
contents: read
|
||||||
|
|
||||||
|
49
.github/workflows/build.yml
vendored
49
.github/workflows/build.yml
vendored
@@ -1,49 +0,0 @@
|
|||||||
name: Build
|
|
||||||
|
|
||||||
on:
|
|
||||||
push: {}
|
|
||||||
merge_group:
|
|
||||||
pull_request:
|
|
||||||
types:
|
|
||||||
- opened
|
|
||||||
- synchronize
|
|
||||||
- ready_for_review
|
|
||||||
|
|
||||||
permissions:
|
|
||||||
contents: read
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
build-mermaid:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v4
|
|
||||||
|
|
||||||
- uses: pnpm/action-setup@v4
|
|
||||||
# uses version from "packageManager" field in package.json
|
|
||||||
|
|
||||||
- name: Setup Node.js
|
|
||||||
uses: actions/setup-node@v4
|
|
||||||
with:
|
|
||||||
cache: pnpm
|
|
||||||
node-version-file: '.node-version'
|
|
||||||
|
|
||||||
- name: Install Packages
|
|
||||||
run: |
|
|
||||||
pnpm install --frozen-lockfile
|
|
||||||
env:
|
|
||||||
CYPRESS_CACHE_FOLDER: .cache/Cypress
|
|
||||||
|
|
||||||
- name: Run Build
|
|
||||||
run: pnpm run build
|
|
||||||
|
|
||||||
- name: Upload Mermaid Build as Artifact
|
|
||||||
uses: actions/upload-artifact@v4
|
|
||||||
with:
|
|
||||||
name: mermaid-build
|
|
||||||
path: packages/mermaid/dist
|
|
||||||
|
|
||||||
- name: Upload Mermaid Mindmap Build as Artifact
|
|
||||||
uses: actions/upload-artifact@v4
|
|
||||||
with:
|
|
||||||
name: mermaid-mindmap-build
|
|
||||||
path: packages/mermaid-mindmap/dist
|
|
26
.github/workflows/checks.yml
vendored
26
.github/workflows/checks.yml
vendored
@@ -1,26 +0,0 @@
|
|||||||
on:
|
|
||||||
push:
|
|
||||||
merge_group:
|
|
||||||
pull_request:
|
|
||||||
types:
|
|
||||||
- opened
|
|
||||||
- synchronize
|
|
||||||
- ready_for_review
|
|
||||||
|
|
||||||
name: Static analysis on Test files
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
check-tests:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
name: check tests
|
|
||||||
if: github.repository_owner == 'mermaid-js'
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v4
|
|
||||||
with:
|
|
||||||
fetch-depth: 0
|
|
||||||
- uses: testomatio/check-tests@stable
|
|
||||||
with:
|
|
||||||
framework: cypress
|
|
||||||
tests: './cypress/e2e/**/**.spec.js'
|
|
||||||
token: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
has-tests-label: true
|
|
2
.github/workflows/e2e-applitools.yml
vendored
2
.github/workflows/e2e-applitools.yml
vendored
@@ -11,6 +11,8 @@ on:
|
|||||||
default: master
|
default: master
|
||||||
description: 'Parent branch to use for PRs'
|
description: 'Parent branch to use for PRs'
|
||||||
|
|
||||||
|
concurrency: ${{ github.workflow }}-${{ github.ref }}
|
||||||
|
|
||||||
permissions:
|
permissions:
|
||||||
contents: read
|
contents: read
|
||||||
|
|
||||||
|
8
.github/workflows/e2e.yml
vendored
8
.github/workflows/e2e.yml
vendored
@@ -2,11 +2,15 @@ name: E2E
|
|||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches-ignore:
|
branches:
|
||||||
- 'gh-readonly-queue/**'
|
- develop
|
||||||
|
- master
|
||||||
|
- release/**
|
||||||
pull_request:
|
pull_request:
|
||||||
merge_group:
|
merge_group:
|
||||||
|
|
||||||
|
concurrency: ${{ github.workflow }}-${{ github.ref }}
|
||||||
|
|
||||||
permissions:
|
permissions:
|
||||||
contents: read
|
contents: read
|
||||||
|
|
||||||
|
13
.github/workflows/lint.yml
vendored
13
.github/workflows/lint.yml
vendored
@@ -4,12 +4,10 @@ on:
|
|||||||
push:
|
push:
|
||||||
merge_group:
|
merge_group:
|
||||||
pull_request:
|
pull_request:
|
||||||
types:
|
|
||||||
- opened
|
|
||||||
- synchronize
|
|
||||||
- ready_for_review
|
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
|
|
||||||
|
concurrency: ${{ github.workflow }}-${{ github.ref }}
|
||||||
|
|
||||||
permissions:
|
permissions:
|
||||||
contents: write
|
contents: write
|
||||||
|
|
||||||
@@ -82,3 +80,10 @@ jobs:
|
|||||||
working-directory: ./packages/mermaid
|
working-directory: ./packages/mermaid
|
||||||
continue-on-error: ${{ github.event_name == 'push' }}
|
continue-on-error: ${{ github.event_name == 'push' }}
|
||||||
run: pnpm run docs:verify
|
run: pnpm run docs:verify
|
||||||
|
|
||||||
|
- uses: testomatio/check-tests@stable
|
||||||
|
with:
|
||||||
|
framework: cypress
|
||||||
|
tests: './cypress/e2e/**/**.spec.js'
|
||||||
|
token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
has-tests-label: true
|
||||||
|
47
.github/workflows/release-publish.yml
vendored
47
.github/workflows/release-publish.yml
vendored
@@ -1,47 +0,0 @@
|
|||||||
name: Publish release
|
|
||||||
|
|
||||||
on:
|
|
||||||
release:
|
|
||||||
types: [published]
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
publish:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v4
|
|
||||||
- uses: fregante/setup-git-user@v2
|
|
||||||
|
|
||||||
- uses: pnpm/action-setup@v4
|
|
||||||
# uses version from "packageManager" field in package.json
|
|
||||||
|
|
||||||
- name: Setup Node.js
|
|
||||||
uses: actions/setup-node@v4
|
|
||||||
with:
|
|
||||||
cache: pnpm
|
|
||||||
node-version-file: '.node-version'
|
|
||||||
|
|
||||||
- name: Install Packages
|
|
||||||
run: |
|
|
||||||
pnpm install --frozen-lockfile
|
|
||||||
npm i json --global
|
|
||||||
env:
|
|
||||||
CYPRESS_CACHE_FOLDER: .cache/Cypress
|
|
||||||
|
|
||||||
- name: Prepare release
|
|
||||||
run: |
|
|
||||||
VERSION=${GITHUB_REF:10}
|
|
||||||
echo "Preparing release $VERSION"
|
|
||||||
git checkout -t origin/release/$VERSION
|
|
||||||
npm version --no-git-tag-version --allow-same-version $VERSION
|
|
||||||
git add package.json
|
|
||||||
git commit -nm "Bump version $VERSION"
|
|
||||||
git checkout -t origin/master
|
|
||||||
git merge -m "Release $VERSION" --no-ff release/$VERSION
|
|
||||||
git push --no-verify
|
|
||||||
|
|
||||||
- name: Publish
|
|
||||||
run: |
|
|
||||||
npm set //registry.npmjs.org/:_authToken $NPM_TOKEN
|
|
||||||
npm publish
|
|
||||||
env:
|
|
||||||
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
|
|
Reference in New Issue
Block a user