From f3de1c79e45c88545ead767a99dd92c33323039a Mon Sep 17 00:00:00 2001 From: ulic-youthlic Date: Sun, 25 May 2025 14:04:21 +0800 Subject: [PATCH] use typos to check typos --- .helix/languages.toml | 18 ++++++++++++++++++ .typos.toml | 21 +++++++++++++++++++++ codebook.toml | 18 ------------------ flake.nix | 1 + home/modules/programs/wluma.nix | 2 +- nixos/modules/programs/juicity/template.nix | 4 ++-- pkgs/helix/runtime.nix | 2 +- 7 files changed, 44 insertions(+), 22 deletions(-) create mode 100644 .helix/languages.toml create mode 100644 .typos.toml delete mode 100644 codebook.toml diff --git a/.helix/languages.toml b/.helix/languages.toml new file mode 100644 index 0000000..0d90ee8 --- /dev/null +++ b/.helix/languages.toml @@ -0,0 +1,18 @@ +[[language]] +name = "nix" +language-servers = ["nixd", "typos-lsp"] + +[[language]] +name = "markdown" +language-servers = ["marksman", "markdown-oxide", "typos-lsp"] + +[[language]] +name = "toml" +language-servers = ["taplo", "typos-lsp"] + +[[language]] +name = "git-ignore" +language-servers = ["typos-lsp"] + +[language-server.typos-lsp] +command = "typos-lsp" diff --git a/.typos.toml b/.typos.toml new file mode 100644 index 0000000..e296d3d --- /dev/null +++ b/.typos.toml @@ -0,0 +1,21 @@ +[files] +ignore-global = true +ignore-parent = true +ignore-hidden = false +ignore-files = true +ignore-vcs = true +extend-exclude = ["secrets/", ".git/", "public-key.txt"] + +[default] +check-filename = true +check-file = true +unicode = true +extend-ignore-re = [ + # Line ignore with trailling `(#|//) spellchecker: disable-line` + "(?Rm)^.*(#|//)\\s*spellchecker: disable-line$", + # Line block with `# spellchecker: ` + "(?s)(#|//)\\s*spellchecker: off.*?\\n\\s*(#|//)\\s*spellchecker: on", +] +extend-ignore-identifiers-re = ["als", "Paket", "ConfiguratioN", "StructurE"] + +[default.extend-identifiers] diff --git a/codebook.toml b/codebook.toml deleted file mode 100644 index 8a78c62..0000000 --- a/codebook.toml +++ /dev/null @@ -1,18 +0,0 @@ -words = [ - "akun", - "configuratio", - "fuzzel", - "gdm", - "ghostty", - "kde", - "niri", - "nixo", - "nixos", - "nixpkgs", - "ovelrays", - "pkgs", - "sddm", - "specialisation", - "structur", - "tytonidae", -] diff --git a/flake.nix b/flake.nix index 436b222..a663bd3 100644 --- a/flake.nix +++ b/flake.nix @@ -180,6 +180,7 @@ packages = with pkgs; [ nixd typos + typos-lsp just nvfetcher ]; diff --git a/home/modules/programs/wluma.nix b/home/modules/programs/wluma.nix index 9c3d06a..061d3e7 100644 --- a/home/modules/programs/wluma.nix +++ b/home/modules/programs/wluma.nix @@ -21,7 +21,7 @@ in { example = pkgs.wluam; default = pkgs.wluma; description = '' - pakcage of wluma + package of wluma ''; }; }; diff --git a/nixos/modules/programs/juicity/template.nix b/nixos/modules/programs/juicity/template.nix index 50ae4fe..7117358 100644 --- a/nixos/modules/programs/juicity/template.nix +++ b/nixos/modules/programs/juicity/template.nix @@ -50,7 +50,7 @@ in { description = '' A file which JSON configurations for juicity client. See the {option}`settings` option for more information. - Note: this file will override {options}`settings` option, which is recommanded. + Note: this file will override {options}`settings` option, which is recommended. ''; }; allowedOpenFirewallPorts = lib.mkOption { @@ -95,7 +95,7 @@ in { description = '' A file which JSON configurations for juicity server. See the {option}`settings` option for more information. - Note: this file will override {options}`settings` option, which is recommanded. + Note: this file will override {options}`settings` option, which is recommended. ''; }; allowedOpenFirewallPorts = lib.mkOption { diff --git a/pkgs/helix/runtime.nix b/pkgs/helix/runtime.nix index 70857b3..ce0e5ec 100644 --- a/pkgs/helix/runtime.nix +++ b/pkgs/helix/runtime.nix @@ -11,7 +11,7 @@ src = grammar.src; # sourceRoot = "source"; - dontConfigue = true; + dontConfigure = true; FLAGS = [ "-Isrc"