-
Notifications
You must be signed in to change notification settings - Fork 2
release: 2.16.1 #77
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
release: 2.16.1 #77
Changes from all commits
f30280d
04b264d
c080ce0
7226291
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,54 @@ | ||
| name: Sync release to main | ||
|
|
||
| on: | ||
| workflow_run: | ||
| workflows: [Release] | ||
| types: [completed] | ||
| branches: [release] | ||
|
|
||
| permissions: | ||
| contents: write | ||
| pull-requests: write | ||
|
|
||
| jobs: | ||
| sync: | ||
| if: github.event.workflow_run.conclusion == 'success' | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - uses: actions/checkout@v5 | ||
| with: | ||
| fetch-depth: 0 | ||
|
|
||
| - name: Check if release is ahead of main | ||
| id: check | ||
| run: | | ||
| git fetch origin main release | ||
| AHEAD=$(git rev-list --count origin/main..origin/release) | ||
| echo "ahead=$AHEAD" >> $GITHUB_OUTPUT | ||
|
|
||
| - name: Create sync PR | ||
| if: steps.check.outputs.ahead != '0' | ||
| env: | ||
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
| run: | | ||
| EXISTING=$(gh pr list --repo ${{ github.repository }} --base main --head release --state open --json number --jq '.[0].number') | ||
| if [ -n "$EXISTING" ]; then | ||
| echo "Sync PR #$EXISTING already exists" | ||
| else | ||
| gh pr create \ | ||
| --repo ${{ github.repository }} \ | ||
| --base main \ | ||
| --head release \ | ||
| --title "chore: sync release to main" \ | ||
| --body "Automated sync of release tags back to main." | ||
| fi | ||
|
|
||
| - name: Auto-merge sync PR | ||
| if: steps.check.outputs.ahead != '0' | ||
| env: | ||
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
| run: | | ||
| PR=$(gh pr list --repo ${{ github.repository }} --base main --head release --state open --json number --jq '.[0].number') | ||
| if [ -n "$PR" ]; then | ||
| gh pr merge "$PR" --repo ${{ github.repository }} --merge | ||
| fi |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -28,7 +28,7 @@ export default async function list(options: Record<string, unknown>) { | |
| } | ||
|
|
||
| const { data, error } = await listBuckets({ | ||
| ...(forksOf || !isPaginated | ||
| ...(forksOf | ||
| ? {} | ||
| : { | ||
| ...(limit !== undefined ? { limit } : {}), | ||
|
|
@@ -57,7 +57,7 @@ export default async function list(options: Record<string, unknown>) { | |
| failWithError(context, infoError); | ||
| } | ||
|
|
||
| if (!bucketInfo.hasForks) { | ||
| if (!bucketInfo.forkInfo?.hasChildren) { | ||
| printEmpty(context); | ||
| return; | ||
| } | ||
|
|
@@ -67,7 +67,10 @@ export default async function list(options: Record<string, unknown>) { | |
| for (const bucket of data.buckets) { | ||
| if (bucket.name === forksOf) continue; | ||
| const { data: info } = await getBucketInfo(bucket.name, { config }); | ||
| if (info?.sourceBucketName === forksOf) { | ||
| const isChildOf = info?.forkInfo?.parents?.some( | ||
| (p) => p.bucketName === forksOf | ||
| ); | ||
| if (isChildOf) { | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Inconsistent JSON output format for fork list commandsMedium Severity The Additional Locations (1)Reviewed by Cursor Bugbot for commit 7226291. Configure here. |
||
| forks.push({ name: bucket.name, created: bucket.creationDate }); | ||
| } | ||
| } | ||
|
|
@@ -99,15 +102,18 @@ export default async function list(options: Record<string, unknown>) { | |
|
|
||
| const nextToken = data.paginationToken || undefined; | ||
|
|
||
| const output = isPaginated | ||
| ? formatPaginatedOutput(buckets, format!, 'buckets', 'bucket', columns, { | ||
| paginationToken: nextToken, | ||
| }) | ||
| : formatOutput(buckets, format!, 'buckets', 'bucket', columns); | ||
| const output = formatPaginatedOutput( | ||
| buckets, | ||
| format!, | ||
| 'buckets', | ||
| 'bucket', | ||
| columns, | ||
| { paginationToken: nextToken } | ||
| ); | ||
|
|
||
| console.log(output); | ||
|
|
||
| if (isPaginated && format !== 'json' && format !== 'xml') { | ||
| if (format !== 'json' && format !== 'xml') { | ||
| printPaginationHint(nextToken); | ||
| } | ||
|
|
||
|
|
||


Uh oh!
There was an error while loading. Please reload this page.