Skip to content

Keep syntax_core; add pub.dev OIDC publish workflow - #14

Merged
leoafarias merged 9 commits into
mainfrom
rename/syntax-to-syntax-darts
Oct 24, 2026
Merged

leoafarias merged 9 commits into
mainfrom
rename/syntax-to-syntax-darts

Conversation

@leoafarias

@leoafarias leoafarias commented Oct 24, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Keeps the core package as syntax_core (directory packages/syntax_core) and adds tag-based pub.dev automated publishing via GitHub Actions OIDC.

This supersedes the interim syntax_darts rename narrative on #13. Do not republish or reconfigure syntax_darts.

Changes

  • Core package remains syntax_core 0.0.1 under packages/syntax_core
  • syntax_flutter 0.0.3 and syntax_noir 0.0.1 depend on hosted syntax_core
  • New .github/workflows/publish.yml: publish on tags
    • syntax_core-v*, syntax_flutter-v*, syntax_noir-v*
    • OIDC (id-token: write); no publish token secret

pub.dev (already configured; out of scope for this PR)

Automated publishing + publisher concepta.dev for syntax_core, syntax_flutter, and syntax_noir on btwld/syntax-dart with matching tag patterns.

Test plan

  • CI green on this PR
  • After merge, tag e.g. syntax_flutter-v0.0.3 only when intentionally publishing

Summary

Keeps the core package as syntax_core (directory packages/syntax_core) and adds tag-based pub.dev automated publishing via GitHub Actions OIDC.

This supersedes the interim syntax_darts rename narrative on #13. Do not republish or reconfigure syntax_darts.

Changes

  • Core package remains syntax_core 0.0.1 under packages/syntax_core
  • syntax_flutter 0.0.3 and syntax_noir 0.0.1 depend on hosted syntax_core
  • syntax_noir no longer path-overrides workspace package syntax_core. Workspace resolution supplies packages/syntax_core; the published dependency stays syntax_core: ^0.0.1
  • CI jobs that still named packages/syntax now use packages/syntax_core. The minimum-sdk job uses Flutter 3.38.1, the oldest stable that can resolve this workspace (syntax_noir requires Dart 3.10)
  • New .github/workflows/publish.yml: publish on tags
    • syntax_core-v*, syntax_flutter-v*, syntax_noir-v*
    • OIDC (id-token: write); no publish token secret

pub.dev (already configured; out of scope for this PR)

Automated publishing + publisher concepta.dev for syntax_core, syntax_flutter, and syntax_noir on btwld/syntax-dart with matching tag patterns.

Test plan

  • CI green on this PR
  • After merge, tag e.g. syntax_flutter-v0.0.3 only when intentionally publishing
Open in Web Open in Cursor 

The name syntax is blocked on pub.dev (moderated tombstone). Point
syntax_flutter and syntax_noir at syntax_core ^0.0.1 and update imports.
pub.dev name syntax is moderated; syntax_core was a wrong interim name.
Point flutter/noir at syntax_darts ^0.0.1.
syntax_flutter 0.0.3 and syntax_noir 0.0.1 depend on hosted syntax_core ^0.0.1.
Triggers on syntax_core-v*, syntax_flutter-v*, syntax_noir-v* and publishes
only the package named in the tag. Requires pub.dev trusted publishing
configured per package; no token secret.
Aligns the checkout with the published syntax_core name and the
tag-based publish workflow (packages/syntax_core).
Restore path override for syntax_noir, fix tool scripts/README, and
list packages/syntax_core in the workspace again.
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 24, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-24T23:29:02.753212Z 5f0ef6c PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 5f0ef6c723

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread pubspec.yaml
sdk: ^3.9.0
workspace:
- packages/syntax
- packages/syntax_core

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Update all CI paths when renaming the core directory

The directory rename leaves .github/workflows/ci.yml pointing at packages/syntax in the formatting step and the core analysis, VM test, Chrome test, and minimum-SDK test steps (lines 43, 49, 63, 69, and 127). Repository-wide search and the Git tree confirm that only packages/syntax_core remains. Consequently, these steps target a nonexistent directory and CI cannot complete successfully. Update these references along with the workspace entry, not just the generated-files diff check.

Useful? React with 👍 / 👎.

Comment thread pubspec.yaml
- packages/syntax
- packages/syntax_core
- packages/syntax_flutter
- packages/syntax_noir

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Keep the Dart 3.10 package outside the minimum-SDK workspace

Adding syntax_noir to this workspace makes the minimum-sdk job in .github/workflows/ci.yml unable to resolve dependencies: that job uses Flutter 3.35/Dart 3.9, whereas packages/syntax_noir/pubspec.yaml:15 requires Dart ^3.10.0. The workspace documentation confirms that resolution includes “all the workspace packages,” so the failure occurs during dependency installation even though the job only tests core and Flutter. Preserve the separate resolution for noir, or provide an isolated workspace configuration for minimum-SDK testing.

Useful? React with 👍 / 👎.

Comment on lines +85 to +86
- name: Set up Flutter (syntax_flutter only)
if: steps.tag.outputs.package == 'syntax_flutter'

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Provide Flutter for every workspace-based publish job

For syntax_core-v* and syntax_noir-v* tags, this condition skips Flutter installation, but the Resolve dependencies step still resolves the root workspace, which includes syntax_flutter and its sdk: flutter dependencies. Installing standalone Dart does not supply those packages, so these two release paths fail before publishing. The SDK dependency documentation requires that “Pub is running in the context of the flutter executable.” Install Flutter and resolve through it for all workspace members, or isolate the selected package from the workspace before resolving.

Useful? React with 👍 / 👎.

Comment thread tool/generate.mjs
@@ -1,4 +1,4 @@
// Generates packages/syntax/lib/langs/*.dart and lib/themes/*.dart from the
// Generates packages/syntax_core/lib/langs/*.dart and lib/themes/*.dart from the

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Retarget the generator and fixture scripts to syntax_core

Despite the updated header and imports, tool/generate.mjs:16 still constructs its output directory using 'packages', 'syntax'. Regeneration therefore recreates the removed directory instead of updating the shipped grammars, themes, and NOTICE; the updated CI diff check only watches packages/syntax_core, so it cannot detect those misplaced outputs. The same stale path remains in tool/golden.mjs:12 and tool/samples.mjs:10, disconnecting fixture generation from the moved conformance tests. Update the actual path constants throughout these tools.

Useful? React with 👍 / 👎.

syntax_noir is a workspace member, so pub rejects a path override of
syntax_core. Keep the hosted dependency and let workspace resolution
supply the sibling package. Point CI at packages/syntax_core, and run
the minimum-sdk job on Flutter 3.38.1 so the workspace can resolve
Dart 3.10.

Co-authored-by: Leo Farias <leoafarias@users.noreply.github.com>
@leoafarias
leoafarias merged commit 4d3e67f into main Oct 24, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants