Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 4 additions & 14 deletions .github/workflows/docs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -52,23 +52,13 @@ jobs:
with:
node-version: 24

- name: Enable Corepack
run: |
corepack enable
corepack prepare yarn@stable --activate

- name: Activate cache for Node.js
uses: actions/setup-node@v6
- name: Install pnpm and dependencies
uses: apify/workflows/pnpm-install@main
with:
node-version: 24
cache: yarn
Comment thread
B4nan marked this conversation as resolved.
cache-dependency-path: impit-node/yarn.lock

- name: Install dependencies
run: cd impit-node && yarn
working-directory: impit-node

- name: Build docs
run: cd impit-node && yarn docs
run: cd impit-node && pnpm run docs

- name: Upload artifact
uses: actions/upload-artifact@v7
Expand Down
29 changes: 11 additions & 18 deletions .github/workflows/node-release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -47,27 +47,18 @@ jobs:
node-version: 24
registry-url: 'https://registry.npmjs.org'

- name: Enable Corepack
run: |
corepack enable
corepack prepare yarn@stable --activate

- name: Activate cache for Node.js
uses: actions/setup-node@v6
- name: Install pnpm and dependencies
uses: apify/workflows/pnpm-install@main
with:
cache: yarn
cache-dependency-path: impit-node/yarn.lock

- name: Install dependencies
run: yarn install
working-directory: impit-node

- name: Download all artifacts
uses: actions/download-artifact@v8
with:
path: artifacts

- name: Move artifacts
run: yarn artifacts
run: pnpm artifacts

- name: List packages
run: ls -R ./npm
Expand All @@ -76,20 +67,20 @@ jobs:
- name: Calculate version
id: get-new-version
run: |
echo ::set-output name=TARGET_VERSION::$(npx semver --increment ${{ github.event.inputs.bump }} $(npm show impit version))
echo "TARGET_VERSION=$(pnpm dlx semver --increment ${{ github.event.inputs.bump }} $(npm show impit version))" >> "$GITHUB_OUTPUT"

- name: Set version
run: |
yarn version ${{ steps.get-new-version.outputs.TARGET_VERSION }}
yarn copy-version
pnpm version --no-git-tag-version ${{ steps.get-new-version.outputs.TARGET_VERSION }}
pnpm copy-version

- name: Publish to npm
run: npm publish --provenance
run: pnpm publish --no-git-checks --provenance

- name: Update lockfile
run: |
for i in $(seq 1 5); do
yarn install --no-immutable && exit 0
pnpm install --lockfile-only && exit 0
[ $i -lt 5 ] && echo "Attempt $i failed, waiting 30s before retry..." && sleep 30
done
exit 1
Expand All @@ -102,6 +93,7 @@ jobs:
author_email: noreply@apify.com
message: "chore(js-release): Update package version [skip ci]"
tag: "js-${{ steps.get-new-version.outputs.TARGET_VERSION }}"
pull: '--rebase --autostash'

changelog:
name: Generate changelog
Expand Down Expand Up @@ -133,6 +125,7 @@ jobs:
author_email: github-actions[bot]@users.noreply.github.com
message: "docs: update changelog [skip ci]"
add: 'impit-node/CHANGELOG.md'
pull: '--rebase --autostash'

- name: Create release
uses: softprops/action-gh-release@v2
Expand Down
Loading
Loading