diff --git a/.nvim.lua b/.nvim.lua new file mode 100644 index 0000000..9e06186 --- /dev/null +++ b/.nvim.lua @@ -0,0 +1,19 @@ +local ok, conform = pcall(require, "conform") +if not ok then + vim.notify("conform.nvim not loaded", vim.log.levels.WARN) + return +end + +conform.setup({ + formatters_by_ft = { + javascript = { "oxfmt" }, + javascriptreact = { "oxfmt" }, + typescript = { "oxfmt" }, + typescriptreact = { "oxfmt" }, + json = { "oxfmt" }, + jsonc = { "oxfmt" }, + }, +}) + +vim.lsp.enable("tsgo") +vim.lsp.enable("oxlint") diff --git a/flake.nix b/flake.nix index 670cab8..d81594b 100644 --- a/flake.nix +++ b/flake.nix @@ -53,9 +53,10 @@ # so source-only edits do not force Bun to reinstall. dependencySource = lib.fileset.toSource { root = ./.; - fileset = lib.fileset.fileFilter ( - file: file.name == "bun.lock" || file.name == "package.json" || file.name == "bunfig.toml" - ) ./.; + fileset = lib.fileset.fileFilter + ( + file: file.name == "bun.lock" || file.name == "package.json" || file.name == "bunfig.toml" + ) ./.; }; # Checks run against a clean source tree, even when using `path:.`. @@ -92,10 +93,12 @@ lib.mapAttrs mkBunScript scripts; mkBunApps = commands: - lib.mapAttrs (name: command: { - type = "app"; - program = "${command}/bin/${name}"; - }) commands; + lib.mapAttrs + (name: command: { + type = "app"; + program = "${command}/bin/${name}"; + }) + commands; mkBunNodeModules = system: pkgs: pkgs.stdenvNoCC.mkDerivation { @@ -255,6 +258,7 @@ pkg-config postgresql python3 + typescript-go watchman ]; linuxPackages = with pkgs; [