-
-
Notifications
You must be signed in to change notification settings - Fork 11
merge dev to main (v3.0.0-beta.15) #354
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
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,115 @@ | ||
| name: Update Sample Repos | ||
|
|
||
| on: | ||
| release: | ||
| types: [published] | ||
| workflow_dispatch: | ||
|
|
||
| permissions: | ||
| contents: read | ||
|
|
||
| jobs: | ||
| update-samples: | ||
| runs-on: ubuntu-latest | ||
| outputs: | ||
| repos: ${{ steps.get-repos.outputs.repos }} | ||
|
|
||
| steps: | ||
| - name: Get all public repos with v3-sample topic in @zenstackhq org | ||
| id: get-repos | ||
| env: | ||
| GH_TOKEN: ${{ secrets.PAT_TOKEN }} | ||
| run: | | ||
| # Get all public repos from the zenstackhq org with v3-sample topic | ||
| REPOS=$(gh repo list zenstackhq --json name,isPrivate,nameWithOwner,repositoryTopics --limit 100 | \ | ||
| jq -r '.[] | select(.isPrivate == false) | select((.repositoryTopics // []) | map(.name) | contains(["v3-sample"])) | .nameWithOwner') | ||
|
|
||
| echo "Found repos with v3-sample topic:" | ||
| echo "$REPOS" | ||
|
|
||
| # Convert to JSON array for matrix | ||
| REPOS_JSON=$(echo "$REPOS" | jq -R -s -c 'split("\n") | map(select(length > 0))') | ||
| echo "repos=$REPOS_JSON" >> $GITHUB_OUTPUT | ||
|
|
||
| - name: Display repos to update | ||
| run: | | ||
| echo "Will update the following repos:" | ||
| echo '${{ steps.get-repos.outputs.repos }}' | jq -r '.[]' | ||
|
|
||
| update-repo: | ||
| needs: update-samples | ||
| runs-on: ubuntu-latest | ||
| if: ${{ needs.update-samples.outputs.repos != '[]' }} | ||
| strategy: | ||
| matrix: | ||
| repo: ${{ fromJson(needs.update-samples.outputs.repos) }} | ||
| fail-fast: false | ||
|
|
||
| steps: | ||
| - name: Checkout target repo | ||
| uses: actions/checkout@v4 | ||
| with: | ||
| repository: ${{ matrix.repo }} | ||
| token: ${{ secrets.PAT_TOKEN }} | ||
|
|
||
| - name: Check if package.json exists | ||
| id: check-package | ||
| run: | | ||
| if [ -f "package.json" ]; then | ||
| echo "exists=true" >> $GITHUB_OUTPUT | ||
| else | ||
| echo "exists=false" >> $GITHUB_OUTPUT | ||
| fi | ||
|
|
||
| - name: Use Node.js | ||
| if: steps.check-package.outputs.exists == 'true' | ||
| uses: actions/setup-node@v4 | ||
| with: | ||
| node-version: 20.x | ||
| cache: 'npm' | ||
|
|
||
| - name: Update @zenstackhq packages to next | ||
| if: steps.check-package.outputs.exists == 'true' | ||
| run: | | ||
| # Get all @zenstackhq packages in the repo | ||
| PACKAGES=$(cat package.json | jq -r ' | ||
| [.dependencies, .devDependencies] | | ||
| add | | ||
| to_entries | | ||
| map(select(.key | startswith("@zenstackhq/"))) | | ||
| map(.key) | | ||
| .[] | ||
| ') | ||
|
|
||
| if [ -z "$PACKAGES" ]; then | ||
| echo "No @zenstackhq packages found in ${{ matrix.repo }}" | ||
| exit 0 | ||
| fi | ||
|
|
||
| echo "Updating packages in ${{ matrix.repo }}:" | ||
| echo "$PACKAGES" | ||
|
|
||
| # Update each package to next tag | ||
| for pkg in $PACKAGES; do | ||
| echo "Updating $pkg to next" | ||
| npm install "$pkg@next" | ||
| done | ||
|
|
||
| # Finally run zenstack generate | ||
| npx zen generate | ||
|
|
||
| - name: Commit and push changes | ||
| if: steps.check-package.outputs.exists == 'true' | ||
| run: | | ||
| git config --global user.name "GitHub Actions Bot" | ||
| git config --global user.email "[email protected]" | ||
|
|
||
| # Check if there are changes to commit | ||
| if git diff --quiet && git diff --staged --quiet; then | ||
| echo "No changes to commit" | ||
| exit 0 | ||
| fi | ||
|
|
||
| git add . | ||
| git commit -m "chore: update @zenstackhq packages to next release" | ||
| git push | ||
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,6 +1,6 @@ | ||
| { | ||
| "name": "zenstack-v3", | ||
| "version": "3.0.0-beta.14", | ||
| "version": "3.0.0-beta.15", | ||
| "description": "ZenStack", | ||
| "packageManager": "[email protected]", | ||
| "scripts": { | ||
|
|
||
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
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,6 +1,6 @@ | ||
| { | ||
| "name": "@zenstackhq/typescript-config", | ||
| "version": "3.0.0-beta.14", | ||
| "version": "3.0.0-beta.15", | ||
| "private": true, | ||
| "license": "MIT" | ||
| } |
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
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
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
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
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,2 @@ | ||
| export * from '@zenstackhq/schema'; | ||
| export type { OperandExpression } from 'kysely'; |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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
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,4 @@ | ||
| import config from '@zenstackhq/eslint-config/base.js'; | ||
|
|
||
| /** @type {import("eslint").Linter.Config} */ | ||
| export default config; |
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,37 @@ | ||
| { | ||
| "name": "@zenstackhq/schema", | ||
| "version": "3.0.0-beta.15", | ||
| "description": "ZenStack Runtime Schema", | ||
| "type": "module", | ||
| "scripts": { | ||
| "build": "tsc --noEmit && tsup-node", | ||
| "watch": "tsup-node --watch", | ||
| "lint": "eslint src --ext ts", | ||
| "pack": "pnpm pack" | ||
| }, | ||
| "keywords": [], | ||
| "author": "ZenStack Team", | ||
| "license": "MIT", | ||
| "files": [ | ||
| "dist" | ||
| ], | ||
| "exports": { | ||
| ".": { | ||
| "import": { | ||
| "types": "./dist/index.d.ts", | ||
| "default": "./dist/index.js" | ||
| }, | ||
| "require": { | ||
| "types": "./dist/index.d.cts", | ||
| "default": "./dist/index.cjs" | ||
| } | ||
| } | ||
| }, | ||
| "dependencies": { | ||
| "decimal.js": "catalog:" | ||
| }, | ||
| "devDependencies": { | ||
| "@zenstackhq/eslint-config": "workspace:*", | ||
| "@zenstackhq/typescript-config": "workspace:*" | ||
| } | ||
| } |
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
File renamed without changes.
3 changes: 1 addition & 2 deletions
3
packages/sdk/src/schema/index.ts → packages/schema/src/index.ts
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,4 +1,3 @@ | ||
| export type * from './expression'; | ||
| export * from './expression-utils'; | ||
| export type * from './schema'; | ||
|
|
||
| export type { OperandExpression } from 'kysely'; |
File renamed without changes.
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,7 @@ | ||
| { | ||
| "extends": "@zenstackhq/typescript-config/base.json", | ||
| "compilerOptions": { | ||
| "noUnusedLocals": false | ||
| }, | ||
| "include": ["src/**/*.ts"] | ||
| } |
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,13 @@ | ||
| import { defineConfig } from 'tsup'; | ||
|
|
||
| export default defineConfig({ | ||
| entry: { | ||
| index: 'src/index.ts', | ||
| }, | ||
| outDir: 'dist', | ||
| splitting: false, | ||
| sourcemap: true, | ||
| clean: true, | ||
| dts: true, | ||
| format: ['cjs', 'esm'], | ||
| }); |
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.