Skip to content

chore: run oxfmt from workspace root#2685

Merged
tido64 merged 1 commit intotrunkfrom
tido/oxfmt-root
Feb 25, 2026
Merged

chore: run oxfmt from workspace root#2685
tido64 merged 1 commit intotrunkfrom
tido/oxfmt-root

Conversation

@tido64
Copy link
Member

@tido64 tido64 commented Feb 25, 2026

Description

Run oxfmt from workspace root

Platforms affected

  • Android
  • iOS
  • macOS
  • visionOS
  • Windows

Test plan

n/a

@tido64 tido64 requested a review from JasonVMo as a code owner February 25, 2026 15:07
@tido64 tido64 enabled auto-merge (squash) February 25, 2026 15:08
Comment on lines +29 to +31
"init": "scripts/init.mjs",
"init-test-app": "scripts/init.mjs",
"configure-test-app": "scripts/configure.mjs",

Choose a reason for hiding this comment

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

Suggested change
"init": "scripts/init.mjs",
"init-test-app": "scripts/init.mjs",
"configure-test-app": "scripts/configure.mjs",
"configure-test-app": "scripts/configure.mjs",
"init": "scripts/init.mjs",
"init-test-app": "scripts/init.mjs",

Copy link
Member Author

@tido64 tido64 Feb 25, 2026

Choose a reason for hiding this comment

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

The order matters because bunx will always choose the first one. See #2418.

"format": "nx run-many --target format:c,format:js,format:swift",
"lint": "nx run-many --target lint:js,lint:kt,lint:rb,lint:swift",
"format:js": "oxfmt $(git ls-files '.github/*.json' '.github/*.yml' '.yarn/plugins/*' '.yarnrc.yml' 'CONTRIBUTING.md' 'README.md' 'nx.json')",
"format:js": "oxfmt '**/README.md' '**/package.json' '*.{cjs,cts,js,mjs,mts,ts,tsx,yml}' '.github/**/*.json' 'CONTRIBUTING.md' 'nx.json' '!packages/app/package.json'",
Copy link
Collaborator

Choose a reason for hiding this comment

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

I guess you don't want to invoke via a script or nx because the slowdown is significant?

Copy link
Collaborator

Choose a reason for hiding this comment

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

Would the leading ** be a perf problem? And is there not a config you can list the files in?

Copy link
Member Author

Choose a reason for hiding this comment

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

I guess you don't want to invoke via a script or nx because the slowdown is significant?

This can be invoked via nx. See the format command.

Would the leading ** be a perf problem? And is there not a config you can list the files in?

The ** is required to match files in subdirectories. I haven't been able to find any configs to list files.

@tido64 tido64 merged commit f84fadf into trunk Feb 25, 2026
29 checks passed
@tido64 tido64 deleted the tido/oxfmt-root branch February 25, 2026 16:41
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