From 6ece3063ab6a2d202e05577ee4995b0b551dbdbf Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 1 Oct 2025 02:02:52 +0000 Subject: [PATCH 1/6] build(deps): bump itertools from 0.13.0 to 0.14.0 Bumps [itertools](https://github.com/rust-itertools/itertools) from 0.13.0 to 0.14.0. - [Changelog](https://github.com/rust-itertools/itertools/blob/master/CHANGELOG.md) - [Commits](https://github.com/rust-itertools/itertools/compare/v0.13.0...v0.14.0) --- updated-dependencies: - dependency-name: itertools dependency-version: 0.14.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- Cargo.lock | 12 +----------- Cargo.toml | 2 +- 2 files changed, 2 insertions(+), 12 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 4389a082..1edd4ab1 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -133,8 +133,7 @@ dependencies = [ "grep-cli", "home", "indexmap", - "itertools 0.13.0", - "itertools 0.14.0", + "itertools", "minus", "nix", "nu-ansi-term", @@ -900,15 +899,6 @@ version = "1.70.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7943c866cc5cd64cbc25b2e01621d07fa8eb2a1a23160ee81ce38704e97b8ecf" -[[package]] -name = "itertools" -version = "0.13.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "413ee7dfc52ee1a4949ceeb7dbc8a33f2d6c088194d9f922fb8318faf1f01186" -dependencies = [ - "either", -] - [[package]] name = "itertools" version = "0.14.0" diff --git a/Cargo.toml b/Cargo.toml index 089822b8..e19f6888 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -74,7 +74,7 @@ encoding_rs = "0.8.35" execute = { version = "0.2.13", optional = true } terminal-colorsaurus = "1.0" unicode-segmentation = "1.12.0" -itertools = "0.13.0" +itertools = "0.14.0" [dependencies.git2] version = "0.20" From d392cea3487149c1ef028a8f60367d20f7acb536 Mon Sep 17 00:00:00 2001 From: DarkMatter-999 Date: Fri, 3 Oct 2025 12:40:59 +0530 Subject: [PATCH 2/6] feat: Add Gomod submodule for go.mod / go.sum syntax support --- .gitmodules | 3 +++ assets/syntaxes/02_Extra/Gomod | 1 + 2 files changed, 4 insertions(+) create mode 160000 assets/syntaxes/02_Extra/Gomod diff --git a/.gitmodules b/.gitmodules index 860bcbb0..1d1b8429 100644 --- a/.gitmodules +++ b/.gitmodules @@ -278,3 +278,6 @@ [submodule "assets/syntaxes/02_Extra/hosts"] path = assets/syntaxes/02_Extra/hosts url = https://github.com/tijn/hosts.tmLanguage +[submodule "assets/syntaxes/02_Extra/Gomod"] + path = assets/syntaxes/02_Extra/Gomod + url = https://github.com/mitranim/sublime-gomod diff --git a/assets/syntaxes/02_Extra/Gomod b/assets/syntaxes/02_Extra/Gomod new file mode 160000 index 00000000..e0200f02 --- /dev/null +++ b/assets/syntaxes/02_Extra/Gomod @@ -0,0 +1 @@ +Subproject commit e0200f024a394d6e7d6b7b37a070bb8ef324b19b From 28ab873a3fc973d3fec36cf9954b75f5f75387e4 Mon Sep 17 00:00:00 2001 From: DarkMatter-999 Date: Fri, 3 Oct 2025 13:00:09 +0530 Subject: [PATCH 3/6] tests: add syntax tests for go.mod and go.sum --- tests/syntax-tests/highlighted/Go/go.mod | 5 +++++ tests/syntax-tests/highlighted/Go/go.sum | 6 ++++++ tests/syntax-tests/source/Go/go.mod | 5 +++++ tests/syntax-tests/source/Go/go.sum | 6 ++++++ 4 files changed, 22 insertions(+) create mode 100644 tests/syntax-tests/highlighted/Go/go.mod create mode 100644 tests/syntax-tests/highlighted/Go/go.sum create mode 100644 tests/syntax-tests/source/Go/go.mod create mode 100644 tests/syntax-tests/source/Go/go.sum diff --git a/tests/syntax-tests/highlighted/Go/go.mod b/tests/syntax-tests/highlighted/Go/go.mod new file mode 100644 index 00000000..0af0c671 --- /dev/null +++ b/tests/syntax-tests/highlighted/Go/go.mod @@ -0,0 +1,5 @@ +module hugeparam + +go 1.25.1 + +require golang.org/x/tools v0.37.0 diff --git a/tests/syntax-tests/highlighted/Go/go.sum b/tests/syntax-tests/highlighted/Go/go.sum new file mode 100644 index 00000000..c64fd034 --- /dev/null +++ b/tests/syntax-tests/highlighted/Go/go.sum @@ -0,0 +1,6 @@ +golang.org/x/mod v0.28.0 h1:gQBtGhjxykdjY9YhZpSlZIsbnaE2+PgjfLWUQTnoZ1U= +golang.org/x/mod v0.28.0/go.mod h1:yfB/L0NOf/kmEbXjzCPOx1iK1fRutOydrCMsqRhEBxI= +golang.org/x/sync v0.17.0 h1:l60nONMj9l5drqw6jlhIELNv9I0A4OFgRsG9k2oT9Ug= +golang.org/x/sync v0.17.0/go.mod h1:9KTHXmSnoGruLpwFjVSX0lNNA75CykiMECbovNTZqGI= +golang.org/x/tools v0.37.0 h1:DVSRzp7FwePZW356yEAChSdNcQo6Nsp+fex1SUW09lE= +golang.org/x/tools v0.37.0/go.mod h1:MBN5QPQtLMHVdvsbtarmTNukZDdgwdwlO5qGacAzF0w= diff --git a/tests/syntax-tests/source/Go/go.mod b/tests/syntax-tests/source/Go/go.mod new file mode 100644 index 00000000..9f229ef3 --- /dev/null +++ b/tests/syntax-tests/source/Go/go.mod @@ -0,0 +1,5 @@ +module hugeparam + +go 1.25.1 + +require golang.org/x/tools v0.37.0 diff --git a/tests/syntax-tests/source/Go/go.sum b/tests/syntax-tests/source/Go/go.sum new file mode 100644 index 00000000..f04bc1a7 --- /dev/null +++ b/tests/syntax-tests/source/Go/go.sum @@ -0,0 +1,6 @@ +golang.org/x/mod v0.28.0 h1:gQBtGhjxykdjY9YhZpSlZIsbnaE2+PgjfLWUQTnoZ1U= +golang.org/x/mod v0.28.0/go.mod h1:yfB/L0NOf/kmEbXjzCPOx1iK1fRutOydrCMsqRhEBxI= +golang.org/x/sync v0.17.0 h1:l60nONMj9l5drqw6jlhIELNv9I0A4OFgRsG9k2oT9Ug= +golang.org/x/sync v0.17.0/go.mod h1:9KTHXmSnoGruLpwFjVSX0lNNA75CykiMECbovNTZqGI= +golang.org/x/tools v0.37.0 h1:DVSRzp7FwePZW356yEAChSdNcQo6Nsp+fex1SUW09lE= +golang.org/x/tools v0.37.0/go.mod h1:MBN5QPQtLMHVdvsbtarmTNukZDdgwdwlO5qGacAzF0w= From 7ee6ee385efd75242aa96950608492671f620345 Mon Sep 17 00:00:00 2001 From: DarkMatter-999 Date: Fri, 3 Oct 2025 13:09:57 +0530 Subject: [PATCH 4/6] docs: update CHANGELOG.md --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index fc2169e9..53b0955e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -57,6 +57,7 @@ - Map `.flatpakref` and `.flatpakrepo` files to INI syntax #3353 (@Ferenc-) - Update hosts syntax #3368 (@keith-hall) - Map `.kshrc` files to Bash syntax #3364 (@ritoban23) +- Add syntax definition and test file for Go modules(`go.mod` and `go.sum`) highlighting, see #3424 (@DarkMatter-999) ## Themes From 7b67981fb9b6743aab8b4e96eff10c6f880e5c75 Mon Sep 17 00:00:00 2001 From: DarkMatter-999 Date: Fri, 3 Oct 2025 13:26:59 +0530 Subject: [PATCH 5/6] tests: fix highlights for Go module syntax --- tests/syntax-tests/highlighted/Go/go.mod | 6 +++--- tests/syntax-tests/highlighted/Go/go.sum | 12 ++++++------ 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/tests/syntax-tests/highlighted/Go/go.mod b/tests/syntax-tests/highlighted/Go/go.mod index 0af0c671..26d11781 100644 --- a/tests/syntax-tests/highlighted/Go/go.mod +++ b/tests/syntax-tests/highlighted/Go/go.mod @@ -1,5 +1,5 @@ -module hugeparam +module hugeparam -go 1.25.1 +go 1.25.1 -require golang.org/x/tools v0.37.0 +require golang.org/x/tools v0.37.0 diff --git a/tests/syntax-tests/highlighted/Go/go.sum b/tests/syntax-tests/highlighted/Go/go.sum index c64fd034..54394747 100644 --- a/tests/syntax-tests/highlighted/Go/go.sum +++ b/tests/syntax-tests/highlighted/Go/go.sum @@ -1,6 +1,6 @@ -golang.org/x/mod v0.28.0 h1:gQBtGhjxykdjY9YhZpSlZIsbnaE2+PgjfLWUQTnoZ1U= -golang.org/x/mod v0.28.0/go.mod h1:yfB/L0NOf/kmEbXjzCPOx1iK1fRutOydrCMsqRhEBxI= -golang.org/x/sync v0.17.0 h1:l60nONMj9l5drqw6jlhIELNv9I0A4OFgRsG9k2oT9Ug= -golang.org/x/sync v0.17.0/go.mod h1:9KTHXmSnoGruLpwFjVSX0lNNA75CykiMECbovNTZqGI= -golang.org/x/tools v0.37.0 h1:DVSRzp7FwePZW356yEAChSdNcQo6Nsp+fex1SUW09lE= -golang.org/x/tools v0.37.0/go.mod h1:MBN5QPQtLMHVdvsbtarmTNukZDdgwdwlO5qGacAzF0w= +golang.org/x/mod v0.28.0 h1:gQBtGhjxykdjY9YhZpSlZIsbnaE2+PgjfLWUQTnoZ1U= +golang.org/x/mod v0.28.0/go.mod h1:yfB/L0NOf/kmEbXjzCPOx1iK1fRutOydrCMsqRhEBxI= +golang.org/x/sync v0.17.0 h1:l60nONMj9l5drqw6jlhIELNv9I0A4OFgRsG9k2oT9Ug= +golang.org/x/sync v0.17.0/go.mod h1:9KTHXmSnoGruLpwFjVSX0lNNA75CykiMECbovNTZqGI= +golang.org/x/tools v0.37.0 h1:DVSRzp7FwePZW356yEAChSdNcQo6Nsp+fex1SUW09lE= +golang.org/x/tools v0.37.0/go.mod h1:MBN5QPQtLMHVdvsbtarmTNukZDdgwdwlO5qGacAzF0w= From f558902ad24ce1bc1e0774f6472d63b9e8824bd5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 2 Oct 2025 17:27:55 +0000 Subject: [PATCH 6/6] build(deps): bump wait-timeout from 0.2.0 to 0.2.1 Bumps [wait-timeout](https://github.com/alexcrichton/wait-timeout) from 0.2.0 to 0.2.1. - [Commits](https://github.com/alexcrichton/wait-timeout/compare/0.2.0...0.2.1) --- updated-dependencies: - dependency-name: wait-timeout dependency-version: 0.2.1 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- Cargo.lock | 4 ++-- Cargo.toml | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 1edd4ab1..14ba58fc 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1857,9 +1857,9 @@ checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426" [[package]] name = "wait-timeout" -version = "0.2.0" +version = "0.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9f200f5b12eb75f8c1ed65abd4b2db8a6e1b138a20de009dacee265a2498f3f6" +checksum = "09ac3b126d3914f9849036f826e054cbabdc8519970b8998ddaf3b5bd3c65f11" dependencies = [ "libc", ] diff --git a/Cargo.toml b/Cargo.toml index e19f6888..85d97474 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -100,7 +100,7 @@ assert_cmd = "2.0.12" expect-test = "1.5.0" serial_test = { version = "2.0.0", default-features = false } predicates = "3.1.3" -wait-timeout = "0.2.0" +wait-timeout = "0.2.1" tempfile = "3.16.0" serde = { version = "1.0", features = ["derive"] }