-
Notifications
You must be signed in to change notification settings - Fork 186
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* build(deps): Bump @babel/core from 7.22.11 to 7.22.15 (#5756) Bumps [@babel/core](https://github.com/babel/babel/tree/HEAD/packages/babel-core) from 7.22.11 to 7.22.15. - [Release notes](https://github.com/babel/babel/releases) - [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md) - [Commits](https://github.com/babel/babel/commits/v7.22.15/packages/babel-core) --- updated-dependencies: - dependency-name: "@babel/core" dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> ----- * tech: Use yarn v3 (#5717) Specify npmPublish* settings Remove vkui yarn.lock As it breaks workspace run command Use npm version to bump version in package.json Use npm version when publish pre-release Use npm version to publish token translator Run size-limit-action more carefully without fake yarn.lock in packages/vkui We cannot keep using fake yarn.lock because Yarn v3 cannot install all dependencies properly by having more than one yarn.lock, even though the second one is fake and empty. Remove yarn-deduplicate package Because modern yarn v3 can do it out of the box Use prepack script during yarn npm publish Because prepublishOnly is no longer supported by Yarn v3. Add yarn binary Because we still have no easy way to use yarn v3 on CI See conversation about it in icons repo: VKCOM/icons#588 (comment) Add yarn plugin to run command for each workspace Currently yarn workspaces foreach is not built into the yarn v3, but will be in yarn v4. No way to avoid .yarn/plugins folder as it is the way yarn plugins designed. See: yarnpkg/berry#4464 Remove install step of condesandbox Turned out yarn v3 cannot run package.json scripts without firstly install all packages with yarn install. On codesandbox thought the `installCommand` command runs package.json script which doesn't work with yarn v3 without `yarn install`. Remove the special install script run, so codesandbox can just run `yarn install` without trying to run package.json script to resolve error: yarn run PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD=1 yarn install (in /tmp/4e439e86) Usage Error: Couldn't find the node_modules state file - running an install might help (findPackageLocation) Use yarn run --top-level|-T to search for jest binary and other binaries those exists in the monorepo top workspace but are missing in the vkui workspace Specify tag without package name like `v${version}` for vkui package This is almost the only one package we publish so, there is no need in such a prefix. Plus it might break the milestone automation from #5447 Add .yarn/* to prettier ignore To avoid fighting with yarn auto format when we udpate something in configuration file automatically --------- Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
- Loading branch information
1 parent
2582c91
commit ea63d80
Showing
27 changed files
with
20,763 additions
and
13,753 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,5 @@ | ||
**/src/**/__image_snapshots__/*.png filter=lfs diff=lfs merge=lfs -text | ||
|
||
# https://yarnpkg.com/getting-started/qa#which-files-should-be-gitignored | ||
/.yarn/releases/** binary | ||
/.yarn/plugins/** binary |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -39,20 +39,36 @@ jobs: | |
registry-url: 'https://registry.npmjs.org' | ||
|
||
- name: Install dependencies | ||
run: yarn install --frozen-lockfile --ignore-scripts | ||
run: YARN_ENABLE_SCRIPTS=false yarn install --immutable | ||
|
||
- name: Set Git credentials | ||
run: | | ||
git config --local user.email "[email protected]" | ||
git config --local user.name "GitHub Action" | ||
- name: Saving current version to env | ||
id: prev_version | ||
run: | | ||
echo "version=$(yarn workspace @vkontakte/vkui node -p "require('./package.json').version")" >> $GITHUB_OUTPUT | ||
- name: Bump by version type | ||
if: ${{ !github.event.inputs.custom_version }} | ||
run: yarn workspace @vkontakte/vkui version --${{ github.event.inputs.type }} --no-commit-hooks | ||
run: yarn workspace @vkontakte/vkui run g:npm:version ${{ github.event.inputs.type }} | ||
|
||
- name: Bump by custom version | ||
if: ${{ github.event.inputs.custom_version }} | ||
run: yarn workspace @vkontakte/vkui version --new-version ${{ github.event.inputs.custom_version }} --no-commit-hooks | ||
run: yarn workspace @vkontakte/vkui run g:npm:version ${{ github.event.inputs.custom_version }} | ||
|
||
- name: Saving updated version to env | ||
id: updated_version | ||
run: | | ||
echo "version=$(yarn workspace @vkontakte/vkui node -p "require('./package.json').version")" >> $GITHUB_OUTPUT | ||
- name: Adding commit and tag with updated version number | ||
run: | | ||
git add -A | ||
git commit -m 'bump(@vkontakte/vkui): from ${{ steps.prev_version.outputs.version }} to ${{ steps.updated_version.outputs.version }}' | ||
git tag v${{ steps.updated_version.outputs.version }} | ||
- name: Run linters | ||
run: yarn run lint | ||
|
@@ -65,21 +81,25 @@ jobs: | |
with: | ||
github_token: ${{ secrets.DEVTOOLS_GITHUB_TOKEN }} | ||
branch: ${{ github.ref }} | ||
tags: true | ||
|
||
- name: Create stable branch | ||
uses: VKCOM/gh-actions/VKUI/stable-branch@main | ||
with: | ||
token: ${{ secrets.DEVTOOLS_GITHUB_TOKEN }} | ||
directory: packages/vkui/ | ||
|
||
- name: Publishing release | ||
run: yarn workspace @vkontakte/vkui publish --non-interactive | ||
- name: Setup NPM Auth Token to .yarnrc.yml | ||
env: | ||
NODE_AUTH_TOKEN: ${{ secrets.NPMJS_PUBLISH_TOKEN }} | ||
shell: bash | ||
run: | | ||
yarn config set npmAlwaysAuth true | ||
yarn config set npmAuthToken $NODE_AUTH_TOKEN | ||
- name: Save updated package version to env | ||
id: updated_version | ||
run: echo "version=$(yarn workspace @vkontakte/vkui --silent run --silent package:version)" >> $GITHUB_OUTPUT | ||
- name: Publishing release | ||
run: | | ||
yarn workspace @vkontakte/vkui npm publish | ||
- name: Creating doc for stable release | ||
run: | | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -48,7 +48,7 @@ jobs: | |
registry-url: 'https://registry.npmjs.org' | ||
|
||
- name: Install dependencies | ||
run: yarn install --frozen-lockfile --ignore-scripts | ||
run: YARN_ENABLE_SCRIPTS=false yarn install --immutable | ||
|
||
- name: Run linters | ||
run: yarn run lint | ||
|
@@ -61,28 +61,48 @@ jobs: | |
git config --local user.email "[email protected]" | ||
git config --local user.name "GitHub Action" | ||
- name: Saving current version to env | ||
id: prev_version | ||
run: | | ||
echo "version=$(yarn workspace @vkontakte/vkui node -p "require('./package.json').version")" >> $GITHUB_OUTPUT | ||
- name: Bump by version type | ||
if: ${{ !github.event.inputs.custom_version }} | ||
run: yarn workspace @vkontakte/vkui version --${{ github.event.inputs.type }} --preid ${{ github.event.inputs.tag }} --no-commit-hooks | ||
run: yarn workspace @vkontakte/vkui run g:npm:version ${{ github.event.inputs.type }} --preid ${{ github.event.inputs.tag }} | ||
|
||
- name: Bump by custom version | ||
if: ${{ github.event.inputs.custom_version }} | ||
run: yarn workspace @vkontakte/vkui version --new-version ${{ github.event.inputs.custom_version }} --no-commit-hooks | ||
run: yarn workspace @vkontakte/vkui run g:npm:version ${{ github.event.inputs.custom_version }} --preid ${{ github.event.inputs.tag }} | ||
|
||
- name: Saving updated version to env | ||
id: updated_version | ||
run: | | ||
echo "version=$(yarn workspace @vkontakte/vkui node -p "require('./package.json').version")" >> $GITHUB_OUTPUT | ||
- name: Adding commit and tag with updated version number | ||
run: | | ||
git add -A | ||
git commit -m 'bump(@vkontakte/vkui): from ${{ steps.prev_version.outputs.version }} to ${{ steps.updated_version.outputs.version }}' | ||
git tag v${{ steps.updated_version.outputs.version }} | ||
- name: Pushing changes | ||
uses: ad-m/github-push-action@master | ||
with: | ||
github_token: ${{ secrets.DEVTOOLS_GITHUB_TOKEN }} | ||
branch: ${{ github.ref }} | ||
tags: true | ||
|
||
- name: Publishing prerelase | ||
run: yarn workspace @vkontakte/vkui publish --non-interactive --tag ${{ github.event.inputs.tag }} | ||
- name: Setup NPM Auth Token to .yarnrc.yml | ||
env: | ||
NODE_AUTH_TOKEN: ${{ secrets.NPMJS_PUBLISH_TOKEN }} | ||
shell: bash | ||
run: | | ||
yarn config set npmAlwaysAuth true | ||
yarn config set npmAuthToken $NODE_AUTH_TOKEN | ||
- name: Save updated package version to env | ||
id: updated_version | ||
run: echo "version=$(yarn workspace @vkontakte/vkui --silent run --silent package:version)" >> $GITHUB_OUTPUT | ||
- name: Publishing release | ||
run: | | ||
yarn workspace @vkontakte/vkui npm publish --tag ${{ github.event.inputs.tag }} | ||
- name: Build styleguide | ||
run: yarn run docs:styleguide:build --dist dist/${{ steps.updated_version.outputs.version }} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -31,7 +31,7 @@ jobs: | |
registry-url: 'https://registry.npmjs.org' | ||
|
||
- name: Install dependencies | ||
run: yarn install --frozen-lockfile | ||
run: YARN_ENABLE_SCRIPTS=false yarn install --immutable | ||
|
||
- name: Run tests | ||
run: yarn run test | ||
|
@@ -44,19 +44,40 @@ jobs: | |
git config --local user.email "[email protected]" | ||
git config --local user.name "GitHub Action" | ||
- name: Saving current version to env | ||
id: prev_version | ||
run: | | ||
echo "version=$(yarn node -p "require('./package.json').version")" >> $GITHUB_OUTPUT | ||
- name: Bump version | ||
run: yarn version --new-version ${{ github.event.inputs.version }} --no-commit-hooks --no-git-tag-version | ||
run: yarn run g:npm:version ${{ github.event.inputs.version }} | ||
|
||
- name: Commit bumped version | ||
run: git add -A && git commit -m '[token-translator] v${{ github.event.inputs.version }}' | ||
- name: Saving updated version to env | ||
id: updated_version | ||
run: | | ||
echo "version=$(yarn node -p "require('./package.json').version")" >> $GITHUB_OUTPUT | ||
- name: Adding commit and tag with updated version number | ||
run: | | ||
git add -A | ||
git commit -m 'bump(@vkontakte/vkui-token-translator): from ${{ steps.prev_version.outputs.version }} to ${{ steps.updated_version.outputs.version }}' | ||
git tag @vkontakte/vkui-token-translator@${{ steps.updated_version.outputs.version }} | ||
- name: Pushing changes | ||
uses: ad-m/github-push-action@master | ||
with: | ||
github_token: ${{ secrets.DEVTOOLS_GITHUB_TOKEN }} | ||
branch: ${{ github.ref }} | ||
tags: true | ||
|
||
- name: Publishing release | ||
run: yarn publish --non-interactive --access public | ||
- name: Setup NPM Auth Token to .yarnrc.yml | ||
env: | ||
NODE_AUTH_TOKEN: ${{ secrets.NPMJS_PUBLISH_TOKEN }} | ||
shell: bash | ||
run: | | ||
yarn config set npmAlwaysAuth true | ||
yarn config set npmAuthToken $NODE_AUTH_TOKEN | ||
- name: Publishing release | ||
run: | | ||
yarn npm publish |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -50,7 +50,7 @@ jobs: | |
cache: 'yarn' | ||
|
||
- name: Install dependencies | ||
run: yarn install --frozen-lockfile --ignore-scripts | ||
run: YARN_ENABLE_SCRIPTS=false yarn install --immutable | ||
|
||
- name: Run Stylelint | ||
run: yarn run lint:style | ||
|
@@ -108,7 +108,7 @@ jobs: | |
cache: 'yarn' | ||
|
||
- name: Install dependencies | ||
run: yarn install --frozen-lockfile --ignore-scripts | ||
run: YARN_ENABLE_SCRIPTS=false yarn install --immutable | ||
|
||
- name: Download Playwright blob reports from GitHub Actions Artifacts | ||
uses: actions/download-artifact@v3 | ||
|
@@ -147,17 +147,17 @@ jobs: | |
cache: 'yarn' | ||
|
||
- name: Install dependencies | ||
run: yarn install --frozen-lockfile --ignore-scripts | ||
run: YARN_ENABLE_SCRIPTS=false yarn install --immutable | ||
|
||
- uses: andresz1/[email protected] | ||
with: | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
# only affects current branch | ||
skip_step: install | ||
directory: packages/vkui/ | ||
# В 1.7.0 пока нет этого свойства. См. packages/vkui/yarn.lock | ||
# package_manager: yarn | ||
build_script: 'size:ci' | ||
script: /bin/bash -c "cd packages/vkui && npx size-limit --json" | ||
|
||
docs_styleguide_upload: | ||
if: ${{ needs.changed_files.outputs.docs_styleguide == 'true' }} | ||
|
@@ -175,7 +175,7 @@ jobs: | |
cache: 'yarn' | ||
|
||
- name: Install dependencies | ||
run: yarn install --frozen-lockfile --ignore-scripts | ||
run: YARN_ENABLE_SCRIPTS=false yarn install --immutable | ||
|
||
- name: Build | ||
run: yarn run docs:styleguide:build | ||
|
@@ -202,7 +202,7 @@ jobs: | |
cache: 'yarn' | ||
|
||
- name: Install dependencies | ||
run: yarn install --frozen-lockfile --ignore-scripts | ||
run: YARN_ENABLE_SCRIPTS=false yarn install --immutable | ||
|
||
- name: Build | ||
run: yarn docs:storybook:build | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -19,3 +19,6 @@ storybook-static/ | |
playwright-report/ | ||
blob-report/ | ||
all-blob-reports/ | ||
|
||
# Yarn | ||
.yarn/* |
Oops, something went wrong.