Add a snippet for adding homepage options to a
...module
This commit is contained in:
parent
c1d0a41346
commit
a5417282da
1 changed files with 33 additions and 0 deletions
|
@ -10,6 +10,39 @@ local fmta = require("luasnip.extras.fmt").fmta
|
|||
ls.add_snippets("nix", {
|
||||
s("homepackages", fmta("home.packages = with pkgs; [ <> ];", i(0))),
|
||||
|
||||
s(
|
||||
"homepage_options",
|
||||
fmta(
|
||||
[[
|
||||
homepage.name = mkOption {
|
||||
default = "<name>";
|
||||
type = types.str;
|
||||
};
|
||||
|
||||
homepage.description = mkOption {
|
||||
default = "<description>";
|
||||
type = types.str;
|
||||
};
|
||||
|
||||
homepage.icon = mkOption {
|
||||
default = "<icon>";
|
||||
type = types.str;
|
||||
};
|
||||
|
||||
homepage.category = mkOption {
|
||||
default = "<finish>";
|
||||
type = types.str;
|
||||
};
|
||||
]],
|
||||
{
|
||||
description = i(2),
|
||||
finish = i(0),
|
||||
icon = i(3),
|
||||
name = i(1),
|
||||
}
|
||||
)
|
||||
),
|
||||
|
||||
s(
|
||||
"imports",
|
||||
fmta(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue