diff --git a/Makefile b/Makefile index 9aea139..3ac4d69 100644 --- a/Makefile +++ b/Makefile @@ -95,3 +95,32 @@ ci: selflint testall clean: rm -fr $(EXE) old-deps old-fennel build/ + +# Steps to release a new fennel-ls version + +# 0. run `make test` and `make selflint`, and/or check builds.sr.ht to ensure things are working. +# 1. Ensure fennel is up to date +# 2. Ensure dkjson is up to date +# 3. Remove "-dev" suffix in version src/fennel-ls/utils.fnl +# 4. Add the version to changelog.md +# 5. Create a commit titled "Release 0.2.2" +# 6. git tag --sign --annotate 0.2.2 +# * For the tag's message, copy the relevant part of the changelog +# git doesn't accept #'s at the start of the line, +# so you need to use ='s instead. For example: +# """ +# = 0.2.2 = +# +# == Bug Fixes == +# * my cool bug fix 1 +# * my cool bug fix 2 +# """ +# 7. `git push origin 0.2.2` +# 8. Bump version at the top of src/fennel-ls/utils.fnl, and add "-dev", +# in a commit titled "change version to 0.2.3-dev" +# 9. XeroOl needs to publish a new version on LuaRocks. +# * The file will probably be the same as the previous one, +# but with a new version number. +# * Test with `luarocks build fennel-ls-0.2.2-1.rockspec --tree my-tree` +# * Upload with `luarocks upload fennel-ls-0.2.2-1.rockspec` +# 10. Celebrate your accomplishment diff --git a/changelog.md b/changelog.md index cf580d8..889afcd 100644 --- a/changelog.md +++ b/changelog.md @@ -1,5 +1,11 @@ # Changelog +### Features +* New lint for replacing (let [] ...) with (do ...) + +### Changes +* Updated to dkjson 2.8 + ## 0.2.1 / 2025-06-06 ### Bug Fixes diff --git a/docs/manual.md b/docs/manual.md index 7f65e5e..1ec0906 100644 --- a/docs/manual.md +++ b/docs/manual.md @@ -102,13 +102,13 @@ to be macro files. ## Features -Feature | Locals | Fields | Builtin Globals | Across Files | Builtins | Macros | User globals | ---------------- | ------ | ------ | --------------- | ------------ | -------- | ------ | ------------ | -Completions | [X] | [X] | [X] | [X] | [X] | [X] | [ ] | -Hover | [X] | [X] | [X] | [X] | [X] | [X] | [ ] | -Goto Definition | [X] | [X] | N/A | [X] | N/A | [ ] | [ ] | -Rename | [X] | [ ] | N/A | [ ] | N/A | [ ] | [ ] | -Goto Reference | [X] | [ ] | [ ] | [ ] | [ ] | [ ] | [ ] | +| Feature | Locals | Fields | Builtin Globals | Across Files | Builtins | Macros | User globals | +| --------------- | ------ | ------ | --------------- | ------------ | -------- | ------ | ------------ | +| Completions | [X] | [X] | [X] | [X] | [X] | [X] | [ ] | +| Hover | [X] | [X] | [X] | [X] | [X] | [X] | [ ] | +| Goto Definition | [X] | [X] | N/A | [X] | N/A | [ ] | [ ] | +| Rename | [X] | [ ] | N/A | [ ] | N/A | [ ] | [ ] | +| Goto Reference | [X] | [ ] | [ ] | [ ] | [ ] | [ ] | [ ] | Fennel-ls can report all fennel compiler errors, plus a few custom lints. diff --git a/src/fennel-ls/utils.fnl b/src/fennel-ls/utils.fnl index 7c25313..663a8f1 100644 --- a/src/fennel-ls/utils.fnl +++ b/src/fennel-ls/utils.fnl @@ -5,7 +5,7 @@ These functions are all pure functions, which makes me happy." (local fennel (require :fennel)) -(local version "0.2.0") +(local version "0.2.2-dev") (λ next-line [str ?from] "Find the start of the next line from a given byte offset, or from the start of the string." diff --git a/tools/require-flags.fnl b/tools/require-flags.fnl index 768a773..4899b43 100644 --- a/tools/require-flags.fnl +++ b/tools/require-flags.fnl @@ -1,15 +1,15 @@ -;; There is no fennel.compiler module on disk to require. -;; It is part of fennel.lua, and doesn't need to be indcuded separately. -(local always-skip [:fennel.compiler]) +;; We only want to include our vendored files +;; If we're falling back to the user's system files, require can find them at runtime; no need to include (local skip-when-file-not-present [[:fennel :deps/fennel.lua] [:dkjson :deps/dkjson.lua]]) +;; The fennel.compiler module has no file to include +(local always-skip [:fennel.compiler]) + (local skip (icollect [_ [module file] (ipairs skip-when-file-not-present) &into always-skip] (if (not (io.open file "r")) - module))) + module))) (when (< 0 (length skip)) (print (.. "--skip-include " (table.concat skip ",")))) - -