nfnl icon indicating copy to clipboard operation
nfnl copied to clipboard

Auto compile cause this error under Windows.

Open UnderCooled opened this issue 7 months ago • 1 comments

After I fixed https://github.com/Olical/nfnl/issues/37 locally, save fennel file will cause this error:

"D:/dev_env/vimconf/nvim/fnl/colors.fnl" [unix] 18L, 1095B [w]
Error detected while processing BufWritePost Autocommands for "<buffer=9>":
Error executing lua callback: ...co/AppData/Local/nvim-data/lazy/nfnl/lua/nfnl/header.lua:13: attempt to index local 's' (a nil value)
stack traceback:
  ...co/AppData/Local/nvim-data/lazy/nfnl/lua/nfnl/header.lua:13: in function 'tagged?'
  ...s/unco/AppData/Local/nvim-data/lazy/nfnl/lua/nfnl/gc.lua:19: in function 'f'
  ...unco/AppData/Local/nvim-data/lazy/nfnl/lua/nfnl/core.lua:154: in function 'f'
  ...unco/AppData/Local/nvim-data/lazy/nfnl/lua/nfnl/core.lua:135: in function 'run_21'
  ...unco/AppData/Local/nvim-data/lazy/nfnl/lua/nfnl/core.lua:160: in function 'find-orphan-lua-files'
  .../unco/AppData/Local/nvim-data/lazy/nfnl/lua/nfnl/api.lua:20: in function 'find-orphans'
  .../AppData/Local/nvim-data/lazy/nfnl/lua/nfnl/callback.lua:16: in function <.../AppData/Local/nvim-data/lazy/nfnl/lua/nfnl/callback.lua:13>

My .nfnl.fnl:

{:source-file-patterns ["fnl/**/*.fnl" "fnl/*.fnl"]
 :compiler-options {:compilerEnv _G}}

UnderCooled avatar May 12 '25 19:05 UnderCooled

Hm interesting! I'm not sure if I've fixed the root cause, but I've added a guard against this string being nil. So this error should go away in the latest commit but I wonder if it will expose another error that this one was masking. Please let me know! Would love to get to the bottom of this for you.

Olical avatar May 16 '25 13:05 Olical