Skip to content

Add oxfmt and oxlint to my setup#96

Merged
kdeal merged 2 commits into
mainfrom
oxfmt
Mar 7, 2026
Merged

Add oxfmt and oxlint to my setup#96
kdeal merged 2 commits into
mainfrom
oxfmt

Conversation

@kdeal

@kdeal kdeal commented Mar 7, 2026

Copy link
Copy Markdown
Owner

I like prettier because it supports a lot of file types, but it has always been slow and a pain to install. oxc fixes this for me by making it a single binary and fast. I mainly wanted oxfmt, but added oxlint since I was already installing oxfmt.

Summary by CodeRabbit

Release Notes

  • Chores
    • Integrated oxfmt as a unified code formatter across CSS, HTML, JavaScript, JSON, TOML, TypeScript, YAML, GraphQL, and Markdown files.
    • Added oxlint as a linter for JavaScript and TypeScript code quality checks.
    • Updated CI/CD pipeline and development tooling to include both formatters and linters.

I like prettier because it supports a lot of file types, but it has
always been slow and a pain to install. oxc fixes this for me by making
it a single binary and fast. I mainly wanted oxfmt, but added oxlint
since I was already installing oxfmt.
@coderabbitai

coderabbitai Bot commented Mar 7, 2026

Copy link
Copy Markdown

Walkthrough

This pull request introduces oxfmt and oxlint as new formatting and linting tools across the project configuration. Changes include: adding oxfmt and oxlint tool definitions to the installation manifest with architecture-specific binaries, updating CI/build pipelines to install oxfmt, adding oxfmt to the justfile format recipe, and reconfiguring Neovim plugins to use oxfmt for formatting and oxlint for linting across multiple file types (CSS, HTML, JavaScript, JSON, TOML, TypeScript, YAML, Markdown, and others), while replacing previous formatters like prettier, mdformat, and jq.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Possibly related PRs

  • Add Buildkite pipeline step for linters #93: Directly modifies the Buildkite pipeline lint step to add oxfmt installation, the same change introduced in this PR's pipeline configuration.
  • Switch to uv, ty, and open code #87: Updates the Neovim LSP servers configuration table by adding new server entries, similar to the oxfmt/oxlint LSP additions in this PR.
  • Try some folke stuff #81: Modifies the Neovim LSP servers configuration with changes to the server setup, affecting the same LSP configuration file being altered here.
🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately summarizes the main objective of the pull request: adding oxfmt and oxlint to the author's development setup.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
  • 📝 Generate docstrings (stacked PR)
  • 📝 Generate docstrings (commit on current branch)
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch oxfmt

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@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: 3e9efef113

ℹ️ 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 xdg_config/nvim/lua/plugins/conform.lua Outdated
javascript = { "prettier" },
json = { "jq" },
graphql = { "oxfmt" },
hmtl = { "oxfmt" },

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 Use correct html filetype key for formatter mapping

The formatters_by_ft table has hmtl instead of html, so Conform will never apply oxfmt to HTML buffers. In practice, formatting-on-save and manual format requests for HTML files will silently skip the configured formatter, which is a regression from the previous explicit HTML formatting setup.

Useful? React with 👍 / 👎.

@coderabbitai coderabbitai 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.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@xdg_config/nvim/lua/plugins/lsp.lua`:
- Around line 36-37: The LSP servers table includes non-LSP tools `oxfmt` and
`oxlint`, which causes nvim-lspconfig to attempt to start invalid servers;
remove the `oxfmt = {}` and `oxlint = {}` entries from the servers table in
lsp.lua so only real language servers are listed (these tools remain configured
separately as a formatter in conform.lua and a linter in lint.lua).

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 3427fc4b-f610-4ef5-be91-2106b3e7f35a

📥 Commits

Reviewing files that changed from the base of the PR and between 0b8c180 and a78a41d.

📒 Files selected for processing (7)
  • .buildkite/pipeline.yml
  • .github/workflows/ci.yml
  • cmd_install.toml
  • justfile
  • xdg_config/nvim/lua/plugins/conform.lua
  • xdg_config/nvim/lua/plugins/lint.lua
  • xdg_config/nvim/lua/plugins/lsp.lua

Comment on lines +36 to +37
oxfmt = {},
oxlint = {},

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🔴 Critical

Remove oxfmt and oxlint from the LSP servers table — they are not language servers.

Both tools are already correctly configured elsewhere:

  • oxfmt is configured as a formatter in conform.lua (lines 31-48)
  • oxlint is configured as a linter in lint.lua (lines 8, 14)

Adding them here will cause errors when nvim-lspconfig attempts to start non-existent LSP server configurations via vim.lsp.enable().

🐛 Proposed fix: Remove the invalid entries
                lua_ls = {},
-               oxfmt = {},
-               oxlint = {},
                ty = {},
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
oxfmt = {},
oxlint = {},
lua_ls = {},
ty = {},
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@xdg_config/nvim/lua/plugins/lsp.lua` around lines 36 - 37, The LSP servers
table includes non-LSP tools `oxfmt` and `oxlint`, which causes nvim-lspconfig
to attempt to start invalid servers; remove the `oxfmt = {}` and `oxlint = {}`
entries from the servers table in lsp.lua so only real language servers are
listed (these tools remain configured separately as a formatter in conform.lua
and a linter in lint.lua).

@kdeal
kdeal merged commit ff8ca09 into main Mar 7, 2026
3 checks passed
@kdeal
kdeal deleted the oxfmt branch March 7, 2026 20:25
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.

1 participant