Commit graph

20 commits

Author SHA1 Message Date
Jordi Lambrechts
57a8fcdf29 fix: check if status.state.foundRC equals vim.NIL
When opening nvim in a directory that does not contain a .envrc file,
this would throw an error on startup.

This is because `vim.json.decode` translates the json null to `vim.NIL`,
which does not match Lua's `nil`
2025-04-23 05:39:35 +02:00
raf
8e8c2a1d6e
Merge pull request #7 from NotAShelf/massive-refactor
Some checks failed
Style & Lint / lint (5.1) (push) Has been cancelled
Style & Lint / style (0.19.1) (push) Has been cancelled
direnv.nvim: complete plugin overhaul
2025-03-21 14:08:32 +00:00
1215bc8871
docs: update API reference, features and TODO 2025-03-19 15:06:01 +03:00
4183b8e162
ignore testing config 2025-03-19 15:01:39 +03:00
66ebab06d0
direnv.nvim: complete plugin overhaul
I should have worked more with atomic commits and less with whatever the
hell this is supposed to be, but hindsight is 20/20. tl;dr is that this
refactor improves the plugin with better UX, slightly better
performance, and better compatibility with Neovim 0.10, which I have
overlooked last time. Changes are, from memory, as follows:

- Caching system to prevent excessive direnv status checks
- Statusline integration to show direnv status in real-time
- Proper async handling for all operations
- Added (subpar) .envrc file editor with creation prompt
- Added autocmd hooks for other plugins (User `DirenvLoaded`, fixes #5)
- Better, comprehensive notification system with proper scheduling
- Intuitive handling of allowed/pending/blocked states
- Added command to check direnv status
- Improved contextual commands and keyboard mappings (despite "best"
  practices)

For those who have direnv.nvim already set up (despite the repo being
archived for months), I tried to retain full backwards compat. New
functionality and error fixes were built on top.
2025-03-19 13:37:37 +03:00
raf
3e38d855c7
Merge pull request #4 from diniamo/main
fix setup_keymaps, fix keymap descriptions
2024-07-08 14:39:12 +00:00
diniamo
8b702a5d35 fix keymap descriptions 2024-07-08 15:56:37 +02:00
diniamo
d4fa88bd63 fix setup_keymaps 2024-07-08 15:40:37 +02:00
raf
abdbf48f56
Merge pull request #3 from diniamo/main
Revert "ensure all keymap commands are valid Lua strings"
2024-07-08 13:18:12 +00:00
diniamo
32985198c5 Revert "ensure all keymap commands are valid Lua strings"
This reverts commit 90f356d4b5.
2024-07-08 15:08:11 +02:00
raf
f50828ef06
Merge pull request #1 from itslychee/plugin_improvements
Various improvements to the plugin
2024-07-04 14:20:24 +00:00
itslychee
20ecd1d869
user_cmd: use one command instead of multiple
* DirenvCheck -> Direnv reload
* DirenvAllow -> Direnv allow
* DirenvDeny -> Direnv deny

Also renames M.check_direnv to M.reload_direnv for better naming.
2024-07-04 07:13:08 -05:00
raf
9500c479f9
Merge pull request #2 from mrshmllow/main
`confirm` & `execute` `direnv export`
2024-07-04 07:03:03 +00:00
marshmallow
3269463590 confirm & execute export 2024-07-04 15:08:29 +10:00
c81f9e52c0
ci: check style & lint Lua code 2024-07-03 21:03:40 +03:00
90f356d4b5
ensure all keymap commands are valid Lua strings 2024-07-03 19:44:04 +03:00
8567799d76
add user commands for calling Direnv manually 2024-07-03 18:56:56 +03:00
91558d1edc
look for .envrc before calling direnv 2024-07-03 18:11:46 +03:00
27abc8e721
initial commit 2024-07-03 17:50:43 +03:00
raf
8d4d32a526
Initial commit 2024-07-03 14:49:58 +00:00