Skip to content

Commit

Permalink
Merge pull request #135 from nabla-studio/davidesegullo/fix-build
Browse files Browse the repository at this point in the history
ci: 💚 remove prerelease and workflow env
  • Loading branch information
DavideSegullo authored Oct 29, 2024
2 parents e7233b1 + aacd820 commit 1200d39
Show file tree
Hide file tree
Showing 6 changed files with 8 additions and 174 deletions.
11 changes: 2 additions & 9 deletions .github/workflows/pr-checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,8 @@ on:
jobs:
checks:
runs-on: ubuntu-latest
environment: ${{ github.base_ref == 'main' && 'production' || github.base_ref == 'v1' && 'production' || 'preview' }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
RELEASE_PREID: ${{ vars.RELEASE_PREID }}
CUSTOM_BASE_REF: ${{ github.base_ref }}
CUSTOM_REF_NAME: ${{ github.ref_name }}
CUSTOM_HEAD_REF: ${{ github.head_ref }}
RELEASE_SPECIFIER: ${{ vars.RELEASE_SPECIFIER }}
RELEASE_TAG: ${{ vars.RELEASE_TAG }}

steps:
# Step 1: Check out the repository code
Expand Down Expand Up @@ -63,7 +56,7 @@ jobs:

# Step 9: Run the release in dry-run mode
- name: Run Nx release version (dry-run)
run: pnpm release
run: pnpm exec nx release --first-release --skip-publish --dry-run

# Step 10: Run publish in dry-run mode
- name: Publish
Expand All @@ -73,7 +66,7 @@ jobs:
# Use npx instead of yarn because yarn automagically sets NPM_* environment variables
# like NPM_CONFIG_REGISTRY so npm publish ends up ignoring the .npmrc file
# which is set up by `setup-node` action.
run: pnpx nx release publish --verbose --dry-run
run: pnpx nx release publish --first-release --verbose --dry-run

# Step 11: Upload artifacts
- name: Upload artifacts
Expand Down
93 changes: 0 additions & 93 deletions .github/workflows/release-preview.yml

This file was deleted.

8 changes: 2 additions & 6 deletions .github/workflows/release-production.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,15 +9,11 @@ on:
jobs:
release:
runs-on: ubuntu-latest
environment: production
permissions:
contents: write
id-token: write # needed for provenance data generation
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
RELEASE_PREID: ${{ vars.RELEASE_PREID }}
RELEASE_SPECIFIER: ${{ vars.RELEASE_SPECIFIER }}
RELEASE_TAG: ${{ vars.RELEASE_TAG }}

steps:
# Step 1: Check out the repository code
Expand Down Expand Up @@ -71,7 +67,7 @@ jobs:

# Step 10: Run the release
- name: Run Nx release version
run: pnpm release -d false
run: pnpm exec nx release --first-release --skip-publish

# Step 11: Run the build for the affected changes
- name: Run build
Expand All @@ -85,7 +81,7 @@ jobs:
# Use npx instead of yarn because yarn automagically sets NPM_* environment variables
# like NPM_CONFIG_REGISTRY so npm publish ends up ignoring the .npmrc file
# which is set up by `setup-node` action.
run: pnpx nx release publish --verbose
run: pnpx nx release publish --first-release --verbose --tag

# Step 13: Upload artifacts
- name: Upload artifacts
Expand Down
16 changes: 4 additions & 12 deletions nx.json
Original file line number Diff line number Diff line change
Expand Up @@ -80,21 +80,13 @@
"release": {
"projects": ["packages/*"],
"projectsRelationship": "independent",
"git": {
"commit": true
},
"version": {
"git": {
"commit": true
},
"generatorOptions": {
"currentVersionResolver": "git-tag",
"specifierSource": "conventional-commits",
"fallbackCurrentVersionResolver": "disk",
"updateDependents": "auto"
}
"conventionalCommits": true
},
"changelog": {
"git": {
"commit": true
},
"projectChangelogs": {
"createRelease": "github"
},
Expand Down
1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
"build": "nx run-many --target=build --exclude nextjs,vue3 --parallel=6",
"test": "nx run-many --target=test --exclude nextjs,vue3 --parallel=6",
"lint": "nx run-many --target=lint --exclude nextjs,vue3 --parallel=6",
"release": "node tools/scripts/release.js",
"prepare": "husky install"
},
"private": true,
Expand Down
53 changes: 0 additions & 53 deletions tools/scripts/release.js

This file was deleted.

0 comments on commit 1200d39

Please sign in to comment.