-
Notifications
You must be signed in to change notification settings - Fork 16
Modularised repo changes v1 #2433
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 4 commits
Commits
Show all changes
29 commits
Select commit
Hold shift + click to select a range
41fe965
removed plugins and updated workflows
shafeeqd959 760d652
updated installation script
shafeeqd959 9b9db77
update unit test workflow
shafeeqd959 36810a1
update unit test workflow
shafeeqd959 e6af960
updated workflows
shafeeqd959 5cf2d0f
updated release flow
shafeeqd959 9fa8a75
fixed unit test cases
shafeeqd959 d9ee237
updated clean script
shafeeqd959 a39f041
updated build with oclif manifest
shafeeqd959 7615b9c
added update lock file script
shafeeqd959 ec8d622
update unit test workflow
shafeeqd959 f955291
updated config test script
shafeeqd959 b19d6e1
updated config test script
shafeeqd959 41de899
update tesconfig
shafeeqd959 2047e3f
update tesconfig
shafeeqd959 c21518c
fixed test cases
shafeeqd959 2c27390
fixed test cases
shafeeqd959 f205c57
fixed test cases
shafeeqd959 78a15a9
fixed test cases
shafeeqd959 35f9dcd
update unit testcase yml
shafeeqd959 652ca0c
updated unit testcase yml
shafeeqd959 f12c92a
updated unit testcase yml
shafeeqd959 8be1c79
updated unit testcase yml
shafeeqd959 423fee8
updated unit testcase yml
shafeeqd959 24f861a
updated unit testcase yml
shafeeqd959 5433c42
updated unit testcase yml
shafeeqd959 0bc99fb
updated unit testcase yml
shafeeqd959 3d8042c
updated unit testcase yml
shafeeqd959 cb6fb36
bumped version
shafeeqd959 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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 hidden or 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 |
|---|---|---|
| @@ -0,0 +1,70 @@ | ||
| name: Release CLI Core (v1 Beta) | ||
|
|
||
| on: | ||
| push: | ||
| branches: [v1-beta] | ||
|
|
||
| jobs: | ||
| build: | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - uses: actions/checkout@v4 | ||
| - uses: pnpm/action-setup@v4 | ||
| with: | ||
| version: 10.28.0 | ||
| - uses: actions/setup-node@v4 | ||
| with: | ||
| node-version: '22.x' | ||
|
|
||
| - name: Enable Corepack | ||
| run: corepack enable | ||
|
|
||
| - name: Install pnpm | ||
| run: corepack prepare pnpm@10.28.0 --activate | ||
|
|
||
| - name: Install root dependencies | ||
| run: pnpm install | ||
|
|
||
| - name: Reading Configuration | ||
| id: release_config | ||
| uses: rgarcia-phi/json-to-variables@v1.1.0 | ||
| with: | ||
| filename: .github/config/release.json | ||
| prefix: release | ||
|
|
||
| # Core CLI | ||
| - name: Installing dependencies of core | ||
| id: core-installation | ||
| if: ${{env.release_releaseAll == 'true' || env.release_plugins_core == 'true'}} | ||
| working-directory: ./packages/contentstack | ||
| run: npm install | ||
| - name: Compiling core | ||
| if: ${{ steps.core-installation.conclusion == 'success' }} | ||
| working-directory: ./packages/contentstack | ||
| run: npm run prepack | ||
| - name: Publishing core (Beta) | ||
| id: publish-core | ||
| uses: JS-DevTools/npm-publish@v3 | ||
| if: ${{ steps.core-installation.conclusion == 'success' }} | ||
| with: | ||
| token: ${{ secrets.NPM_TOKEN }} | ||
| package: ./packages/contentstack/package.json | ||
| tag: beta | ||
|
|
||
| - name: Create Core Beta Release | ||
| if: ${{ steps.publish-core.conclusion == 'success' }} | ||
| id: create_release | ||
| env: | ||
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
| VERSION: ${{ steps.publish-core.outputs.version }} | ||
| run: | | ||
| # Look for the last release specifically starting with the 'core@v' prefix | ||
| PREVIOUS_BETA=$(gh release list --limit 50 | grep 'core@v' | grep 'beta' | head -1 | cut -f1) | ||
|
|
||
| if [ -n "$PREVIOUS_BETA" ]; then | ||
| # Compare current core version against previous core version | ||
| gh release create "core@v$VERSION" --title "Core Beta $VERSION" --notes-from-tag "$PREVIOUS_BETA" --prerelease | ||
| else | ||
| # Fallback if this is the first core@v release | ||
| gh release create "core@v$VERSION" --title "Core Beta $VERSION" --generate-notes --prerelease | ||
| fi | ||
This file contains hidden or 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 |
|---|---|---|
| @@ -0,0 +1,141 @@ | ||
| name: Release CLI Platform Plugins (v1 Beta) | ||
|
|
||
| on: | ||
| push: | ||
| branches: [v1-beta] | ||
|
|
||
| jobs: | ||
| build: | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - uses: actions/checkout@v4 | ||
| - uses: pnpm/action-setup@v4 | ||
| with: | ||
| version: 7 | ||
| - uses: actions/setup-node@v4 | ||
| with: | ||
| node-version: '22.x' | ||
|
|
||
| - name: Enable Corepack | ||
| run: corepack enable | ||
|
|
||
| - name: Install pnpm | ||
| run: corepack prepare pnpm@7 --activate | ||
|
|
||
| - name: Install root dependencies | ||
| run: pnpm install | ||
|
|
||
| - name: Reading Configuration | ||
| id: release_config | ||
| uses: rgarcia-phi/json-to-variables@v1.1.0 | ||
| with: | ||
| filename: .github/config/release.json | ||
| prefix: release | ||
|
|
||
| # Dev Dependencies | ||
| - name: Installing dependencies of dev dependencies | ||
| id: dev-dependencies-installation | ||
| if: ${{env.release_releaseAll == 'true' || env.release_plugins_dev-dependencies == 'true'}} | ||
| working-directory: ./packages/contentstack-dev-dependencies | ||
| run: npm install | ||
| - name: Compiling dev dependencies | ||
| if: ${{ steps.dev-dependencies-installation.conclusion == 'success' }} | ||
| working-directory: ./packages/contentstack-dev-dependencies | ||
| run: npm run prepack | ||
| - name: Publishing dev dependencies (Beta) | ||
| uses: JS-DevTools/npm-publish@v3 | ||
| if: ${{ steps.dev-dependencies-installation.conclusion == 'success' }} | ||
| with: | ||
| token: ${{ secrets.NPM_TOKEN }} | ||
| package: ./packages/contentstack-dev-dependencies/package.json | ||
| tag: beta | ||
|
|
||
| # Utilities | ||
| - name: Installing dependencies of utilities | ||
| id: utilities-installation | ||
| if: ${{env.release_releaseAll == 'true' || env.release_plugins_utilities == 'true'}} | ||
| working-directory: ./packages/contentstack-utilities | ||
| run: npm install | ||
| - name: Compiling utilities | ||
| if: ${{ steps.utilities-installation.conclusion == 'success' }} | ||
| working-directory: ./packages/contentstack-utilities | ||
| run: npm run prepack | ||
| - name: Publishing utilities (Beta) | ||
| uses: JS-DevTools/npm-publish@v3 | ||
| if: ${{ steps.utilities-installation.conclusion == 'success' }} | ||
| with: | ||
| token: ${{ secrets.NPM_TOKEN }} | ||
| package: ./packages/contentstack-utilities/package.json | ||
| tag: beta | ||
|
|
||
| # Command | ||
| - name: Installing dependencies of command | ||
| id: command-installation | ||
| if: ${{env.release_releaseAll == 'true' || env.release_plugins_command == 'true'}} | ||
| working-directory: ./packages/contentstack-command | ||
| run: npm install | ||
| - name: Compiling command | ||
| if: ${{ steps.command-installation.conclusion == 'success' }} | ||
| working-directory: ./packages/contentstack-command | ||
| run: npm run prepack | ||
| - name: Publishing command (Beta) | ||
| uses: JS-DevTools/npm-publish@v3 | ||
| if: ${{ steps.command-installation.conclusion == 'success' }} | ||
| with: | ||
| token: ${{ secrets.NPM_TOKEN }} | ||
| package: ./packages/contentstack-command/package.json | ||
| tag: beta | ||
|
|
||
| # Config | ||
| - name: Installing dependencies of config | ||
| id: config-installation | ||
| if: ${{env.release_releaseAll == 'true' || env.release_plugins_config == 'true'}} | ||
| working-directory: ./packages/contentstack-config | ||
| run: npm install | ||
| - name: Compiling config | ||
| if: ${{ steps.config-installation.conclusion == 'success' }} | ||
| working-directory: ./packages/contentstack-config | ||
| run: npm run prepack | ||
| - name: Publishing config (Beta) | ||
| uses: JS-DevTools/npm-publish@v3 | ||
| if: ${{ steps.config-installation.conclusion == 'success' }} | ||
| with: | ||
| token: ${{ secrets.NPM_TOKEN }} | ||
| package: ./packages/contentstack-config/package.json | ||
| tag: beta | ||
|
|
||
| # Auth | ||
| - name: Installing dependencies of auth | ||
| id: auth-installation | ||
| if: ${{env.release_releaseAll == 'true' || env.release_plugins_auth == 'true'}} | ||
| working-directory: ./packages/contentstack-auth | ||
| run: npm install | ||
| - name: Compiling auth | ||
| if: ${{ steps.auth-installation.conclusion == 'success' }} | ||
| working-directory: ./packages/contentstack-auth | ||
| run: npm run prepack | ||
| - name: Publishing auth (Beta) | ||
| uses: JS-DevTools/npm-publish@v3 | ||
| if: ${{ steps.auth-installation.conclusion == 'success' }} | ||
| with: | ||
| token: ${{ secrets.NPM_TOKEN }} | ||
| package: ./packages/contentstack-auth/package.json | ||
| tag: beta | ||
|
|
||
| - name: Create Platform Plugins Beta Release | ||
| # Adjust the ID below to match your actual publishing step ID for plugins | ||
| if: ${{ steps.publish-plugins.conclusion == 'success' }} | ||
| id: create_release_plugins | ||
| env: | ||
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
| # Extract version from the output of your plugin publish step | ||
| VERSION: ${{ steps.publish-plugins.outputs.version }} | ||
| run: | | ||
| # Look for the last release specifically starting with 'plugins@v' | ||
| PREVIOUS_BETA=$(gh release list --limit 50 | grep 'platform-plugins@v' | grep 'beta' | head -1 | cut -f1) | ||
|
|
||
| if [ -n "$PREVIOUS_BETA" ]; then | ||
| gh release create "platform-plugins@v$VERSION" --title "Platform Plugins Beta $VERSION" --notes-from-tag "$PREVIOUS_BETA" --prerelease | ||
| else | ||
| gh release create "platform-plugins@v$VERSION" --title "Platform Plugins Beta $VERSION" --generate-notes --prerelease | ||
| fi |
This file contains hidden or 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 hidden or 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,9 @@ | ||
| # shamefully-hoist=true | ||
| # Use workspace protocol for local development | ||
| link-workspace-packages=true | ||
| prefer-workspace-packages=true | ||
|
|
||
| # Hoist dependencies to root node_modules | ||
| shamefully-hoist=true | ||
|
|
||
| # Use strict peer dependencies | ||
| strict-peer-dependencies=false |
This file contains hidden or 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,8 +1,8 @@ | ||
| fileignoreconfig: | ||
| - filename: package-lock.json | ||
| checksum: c91b9e5fba1c84c0b6de15ad2f8cce698a5c781c9db31bebb7a3ad63ee88d9e1 | ||
| - filename: pnpm-lock.yaml | ||
| checksum: 8405d813bbcc584a7540542acfdbc27f5b8768da60354b7eff9f6cd93c3d832d | ||
| - filename: packages/contentstack-bootstrap/src/bootstrap/utils.ts | ||
| checksum: 6e6fb00bb11b03141e5ad27eeaa4af9718dc30520c3e73970bc208cc0ba2a7d2 | ||
| - filename: package-lock.json | ||
| checksum: c91b9e5fba1c84c0b6de15ad2f8cce698a5c781c9db31bebb7a3ad63ee88d9e1 | ||
| - filename: pnpm-lock.yaml | ||
| checksum: 979a1e1bbcbd772d7555db2dfacf2b8eca6b80ce6353ccaad98f19f31e05e9f2 | ||
| - filename: packages/contentstack-bootstrap/src/bootstrap/utils.ts | ||
| checksum: 6e6fb00bb11b03141e5ad27eeaa4af9718dc30520c3e73970bc208cc0ba2a7d2 | ||
| version: '1.0' |
This file contains hidden or 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,7 +1,7 @@ | ||
| #!/bin/bash | ||
|
|
||
| echo 'Installing Contentstack CLI' | ||
| npm run setup-repo || { echo -e '\e[31mFailed to install root dependencies.' && exit 1; } | ||
| npm run setup || { echo -e '\e[31mFailed to install root dependencies.' && exit 1; } | ||
| echo 'Installtion, Done!!!' | ||
| cd packages/contentstack || { echo -e '\e[31mCould not found the working directory.' && exit 1; } | ||
| ./bin/run --help |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.