Skip to content

Commit

Permalink
Merge branch 'minor' into feat/tsx-generics
Browse files Browse the repository at this point in the history
  • Loading branch information
Procrustes5 committed Aug 16, 2024
2 parents 236be53 + 77d5e88 commit 15a5269
Show file tree
Hide file tree
Showing 233 changed files with 5,699 additions and 4,459 deletions.
8 changes: 4 additions & 4 deletions .github/commit-convention.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ This reverts commit 667ecc1654a317a13331b17617d973392f415f02.

### Full Message Format

A commit message consists of a **header**, **body** and **footer**. The header has a **type**, **scope** and **subject**:
A commit message consists of a **header**, **body** and **footer**. The header has a **type**, **scope** and **subject**:

```
<type>(<scope>): <subject>
Expand Down Expand Up @@ -74,9 +74,9 @@ The scope could be anything specifying the place of the commit change. For examp

The subject contains a succinct description of the change:

* use the imperative, present tense: "change" not "changed" nor "changes"
* don't capitalize the first letter
* no dot (.) at the end
- use the imperative, present tense: "change" not "changed" nor "changes"
- don't capitalize the first letter
- no dot (.) at the end

### Body

Expand Down
1 change: 0 additions & 1 deletion .github/contributing.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ Hi! I'm really excited that you are interested in contributing to Vue.js. Before

Another aspect of it is that large scale stylistic changes result in massive diffs that touch multiple files, adding noise to the git history and makes tracing behavior changes across commits more cumbersome.


### Pull Request Checklist

- Vue core has two primary work branches: `main` and `minor`.
Expand Down
1 change: 1 addition & 0 deletions .github/maintenance.md
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ Depending on the type of the PR, different considerations need to be taken into
- Make sure it doesn't accidentally cause dev-only or compiler-only code branches to be included in the runtime build. Notable case is that some functions in @vue/shared are compiler-only and should not be used in runtime code, e.g. `isHTMLTag` and `isSVGTag`.

- Performance

- Be careful about code changes in "hot paths", in particular the Virtual DOM renderer (`runtime-core/src/renderer.ts`) and component instantiation code.

- Potential Breakage
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/canary-minor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,6 @@ jobs:

- run: pnpm install

- run: pnpm release --canary --tag minor
- run: pnpm release --canary --publish --tag minor
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
2 changes: 1 addition & 1 deletion .github/workflows/canary.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,6 @@ jobs:

- run: pnpm install

- run: pnpm release --canary
- run: pnpm release --canary --publish
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
135 changes: 3 additions & 132 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,136 +8,7 @@ on:
- main
- minor

permissions:
contents: read # to fetch code (actions/checkout)

jobs:
unit-test:
runs-on: ubuntu-latest
if: github.event_name == 'push' || github.event.pull_request.head.repo.full_name != github.repository
env:
PUPPETEER_SKIP_DOWNLOAD: 'true'
steps:
- uses: actions/checkout@v4

- name: Install pnpm
uses: pnpm/action-setup@v4.0.0

- name: Install Node.js
uses: actions/setup-node@v4
with:
node-version-file: '.node-version'
cache: 'pnpm'

- run: pnpm install

- name: Run unit tests
run: pnpm run test-unit

unit-test-windows:
runs-on: windows-latest
if: github.event_name == 'push' || github.event.pull_request.head.repo.full_name != github.repository
env:
PUPPETEER_SKIP_DOWNLOAD: 'true'
steps:
- uses: actions/checkout@v4

- name: Install pnpm
uses: pnpm/action-setup@v4.0.0

- name: Install Node.js
uses: actions/setup-node@v4
with:
node-version-file: '.node-version'
cache: 'pnpm'

- run: pnpm install

- name: Run compiler unit tests
run: pnpm run test-unit compiler

- name: Run ssr unit tests
run: pnpm run test-unit server-renderer

e2e-test:
runs-on: ubuntu-latest
if: github.event_name == 'push' || github.event.pull_request.head.repo.full_name != github.repository
steps:
- uses: actions/checkout@v4

- name: Setup cache for Chromium binary
uses: actions/cache@v4
with:
path: ~/.cache/puppeteer
key: chromium-${{ hashFiles('pnpm-lock.yaml') }}

- name: Install pnpm
uses: pnpm/action-setup@v4.0.0

- name: Install Node.js
uses: actions/setup-node@v4
with:
node-version-file: '.node-version'
cache: 'pnpm'

- run: pnpm install
- run: node node_modules/puppeteer/install.mjs

- name: Run e2e tests
run: pnpm run test-e2e

- name: verify treeshaking
run: node scripts/verify-treeshaking.js

lint-and-test-dts:
runs-on: ubuntu-latest
if: github.event_name == 'push' || github.event.pull_request.head.repo.full_name != github.repository
env:
PUPPETEER_SKIP_DOWNLOAD: 'true'
steps:
- uses: actions/checkout@v4

- name: Install pnpm
uses: pnpm/action-setup@v4.0.0

- name: Install Node.js
uses: actions/setup-node@v4
with:
node-version-file: '.node-version'
cache: 'pnpm'

- run: pnpm install

- name: Run eslint
run: pnpm run lint

- name: Run prettier
run: pnpm run format-check

- name: Run type declaration tests
run: pnpm run test-dts

# benchmarks:
# runs-on: ubuntu-latest
# if: github.event_name == 'push' || github.event.pull_request.head.repo.full_name != github.repository
# env:
# PUPPETEER_SKIP_DOWNLOAD: 'true'
# steps:
# - uses: actions/checkout@v4

# - name: Install pnpm
# uses: pnpm/action-setup@v3.0.0

# - name: Install Node.js
# uses: actions/setup-node@v4
# with:
# node-version-file: '.node-version'
# cache: 'pnpm'

# - run: pnpm install

# - name: Run benchmarks
# uses: CodSpeedHQ/action@v2
# with:
# run: pnpm vitest bench --run
# token: ${{ secrets.CODSPEED_TOKEN }}
test:
if: ${{ ! startsWith(github.event.head_commit.message, 'release:') && (github.event_name == 'push' || github.event.pull_request.head.repo.full_name != github.repository) }}
uses: ./.github/workflows/test.yml
28 changes: 0 additions & 28 deletions .github/workflows/release-tag.yml

This file was deleted.

55 changes: 55 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
name: Release

on:
push:
tags:
- 'v*' # Push events to matching v*, i.e. v1.0, v20.15.10

jobs:
test:
uses: ./.github/workflows/test.yml

release:
# prevents this action from running on forks
if: github.repository == 'vuejs/core'
needs: [test]
runs-on: ubuntu-latest
permissions:
contents: write
id-token: write
# Use Release environment for deployment protection
environment: Release
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Install pnpm
uses: pnpm/action-setup@v4

- name: Install Node.js
uses: actions/setup-node@v4
with:
node-version-file: '.node-version'
registry-url: 'https://registry.npmjs.org'
cache: 'pnpm'

- name: Install deps
run: pnpm install

- name: Build and publish
id: publish
run: |
pnpm release --publishOnly
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

- name: Create GitHub release
id: release_tag
uses: yyx990803/release-tag@master
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.ref }}
body: |
For stable releases, please refer to [CHANGELOG.md](https://github.com/vuejs/core/blob/main/CHANGELOG.md) for details.
For pre-releases, please refer to [CHANGELOG.md](https://github.com/vuejs/core/blob/minor/CHANGELOG.md) of the `minor` branch.
17 changes: 7 additions & 10 deletions .github/workflows/size-data.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ on:
push:
branches:
- main
- minor
pull_request:
branches:
- main
Expand Down Expand Up @@ -36,18 +37,14 @@ jobs:

- run: pnpm run size

- name: Save PR number & base branch
if: ${{github.event_name == 'pull_request'}}
run: |
echo ${{ github.event.number }} > ./temp/size/number.txt
echo ${{ github.base_ref }} > ./temp/size/base.txt
- name: Upload Size Data
uses: actions/upload-artifact@v4
with:
name: size-data
path: temp/size

- name: Save PR number
if: ${{github.event_name == 'pull_request'}}
run: echo ${{ github.event.number }} > ./pr.txt

- uses: actions/upload-artifact@v4
if: ${{github.event_name == 'pull_request'}}
with:
name: pr-number
path: pr.txt
23 changes: 9 additions & 14 deletions .github/workflows/size-report.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,30 +35,25 @@ jobs:
- name: Install dependencies
run: pnpm install

- name: Download PR number
- name: Download Size Data
uses: dawidd6/action-download-artifact@v6
with:
name: pr-number
name: size-data
run_id: ${{ github.event.workflow_run.id }}
path: /tmp/pr-number
path: temp/size

- name: Read PR Number
id: pr-number
uses: juliangruber/read-file-action@v1
with:
path: /tmp/pr-number/pr.txt
run: echo "number=(cat ./temp/size/number.txt)" >> $GITHUB_OUTPUT

- name: Download Size Data
uses: dawidd6/action-download-artifact@v6
with:
name: size-data
run_id: ${{ github.event.workflow_run.id }}
path: temp/size
- name: Read base branch
id: pr-base
run: echo "base=(cat ./temp/size/base.txt)" >> $GITHUB_OUTPUT

- name: Download Previous Size Data
uses: dawidd6/action-download-artifact@v6
with:
branch: main
branch: ${{ steps.pr-base.outputs.base }}
workflow: size-data.yml
event: push
name: size-data
Expand All @@ -78,7 +73,7 @@ jobs:
uses: actions-cool/maintain-one-comment@v3
with:
token: ${{ secrets.GITHUB_TOKEN }}
number: ${{ steps.pr-number.outputs.content }}
number: ${{ steps.pr-number.outputs.number }}
body: |
${{ steps.size-report.outputs.content }}
<!-- VUE_CORE_SIZE -->
Expand Down
Loading

0 comments on commit 15a5269

Please sign in to comment.