Skip to content

Commit

Permalink
build(extras): use lazy.minit for building extras
Browse files Browse the repository at this point in the history
closes #37
  • Loading branch information
miikanissi committed Oct 11, 2024
1 parent c36dc9f commit 32f3c1b
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 1 deletion.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,4 @@ debug
.vscode
.settings
.idea
.tests/
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ How to create a new extra template:
plugin directory:

```sh
nvim --headless "+lua require('modus-themes.extras').setup()" +qa
./scripts/extras.sh
```

4. Ensure the newly created themes in the `extras/` directory are correct. Please **DO
Expand Down
3 changes: 3 additions & 0 deletions scripts/extras.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#!/bin/sh

nvim -u tests/minit.lua --headless +"lua require('modus-themes.extras').setup()" +qa
15 changes: 15 additions & 0 deletions tests/minit.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
#!/usr/bin/env -S nvim -l

vim.env.LAZY_STDPATH = ".tests"
vim.env.LAZY_PATH = vim.fs.normalize("~/projects/lazy.nvim")
load(vim.fn.system("curl -s https://raw.githubusercontent.com/folke/lazy.nvim/main/bootstrap.lua"))()

-- Setup lazy
require("lazy.minit").setup({
spec = {
{
dir = vim.uv.cwd(),
opts = {},
},
},
})

0 comments on commit 32f3c1b

Please sign in to comment.