diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a66f34b..0665e00 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -58,6 +58,13 @@ jobs: bin: codebook-lsp.exe name: codebook-lsp-x86_64-pc-windows-msvc.zip command: build + - release_for: Windows-arm64 + os: windows-latest + target: aarch64-pc-windows-msvc + project: codebook-lsp + bin: codebook-lsp.exe + name: codebook-lsp-aarch64-pc-windows-msvc.zip + command: build - release_for: macOS-x86_64 os: macOS-latest target: x86_64-apple-darwin diff --git a/CHANGELOG.md b/CHANGELOG.md index cfb9d73..ff4f69b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,8 @@ +[Unreleased] + +- Add Windows ARM64 release artifacts +- Move dictionary cache directory to platform-specific data directories instead of /tmp + [0.3.18] - Fixed f-string issues in Python diff --git a/README.md b/README.md index 4e5e8af..45487a4 100644 --- a/README.md +++ b/README.md @@ -16,10 +16,12 @@ Example -No setup needed. Codebook will automatically detect the language you are editing and mark issues for you. Note, Codebook will only mark issues for words that you control, where they are initially defined. +No configuration needed. Codebook will automatically detect the language you are editing and mark issues for you. Codebook will try to only mark issues for words that you create, where they are initially defined. Please gift a ⭐ if you find Codebook useful! +**Supported platforms:** Prebuilt archives are published for macOS (x86_64, aarch64), Linux (x86_64, aarch64), and Windows (x86_64, arm64). + ## Integrations ### Zed @@ -158,7 +160,9 @@ If you are a Zed user, you may skip this step and consult the [Zed section](#zed ### Manual 1. Download the latest release for your architecture from the [releases](https://github.com/blopker/codebook/releases) page. -2. Extract the binary from the tarball, and move it somewhere on your system `$PATH`. + - Prebuilt archives are published for macOS (x86_64, aarch64), Linux (x86_64, aarch64), and Windows (x86_64, arm64). + - Windows artifacts are provided as `.zip` files; macOS and Linux artifacts are `.tar.gz`. +2. Extract the binary from the archive, and move it somewhere on your system `$PATH`. - `~/.local/bin/codebook-lsp` - `/usr/bin/codebook-lsp` - Etc... diff --git a/crates/codebook/src/parser.rs b/crates/codebook/src/parser.rs index 4afa164..b7180cf 100644 --- a/crates/codebook/src/parser.rs +++ b/crates/codebook/src/parser.rs @@ -217,13 +217,15 @@ fn find_locations_code( end_byte: range.end_byte + node_start_byte, }; if let Some(existing_result) = word_locations.get_mut(&word_pos.word) { - let added = existing_result.insert(location); #[cfg(debug_assertions)] - if !added { - let word = word_pos.word.clone(); - panic!( - "Two of the same locations found. Make a better query. Word: {word}, Location: {location:?}" - ) + { + let added = existing_result.insert(location); + if !added { + let word = word_pos.word.clone(); + panic!( + "Two of the same locations found. Make a better query. Word: {word}, Location: {location:?}" + ) + } } } else { let mut set = HashSet::new();