mirror of
https://github.com/nix-community/nixvim.git
synced 2025-06-20 08:05:43 +02:00
readme: fix & simplify simple flake example
This commit is contained in:
parent
99a2f96cf0
commit
797c075db2
1 changed files with 25 additions and 24 deletions
49
README.md
49
README.md
|
@ -203,38 +203,39 @@ can use the following:
|
|||
{
|
||||
description = "A very basic flake";
|
||||
|
||||
inputs.nixvim.url = "github:nix-community/nixvim";
|
||||
inputs = {
|
||||
nixpkgs.follows = "nixvim/nixpkgs";
|
||||
nixvim.url = "github:nix-community/nixvim";
|
||||
};
|
||||
|
||||
outputs =
|
||||
{ nixpkgs, nixvim, ... }:
|
||||
let
|
||||
config = {
|
||||
colorschemes.gruvbox.enable = true;
|
||||
};
|
||||
|
||||
outputs = {
|
||||
self,
|
||||
nixvim,
|
||||
flake-parts,
|
||||
} @ inputs: let
|
||||
config = {
|
||||
colorschemes.gruvbox.enable = true;
|
||||
};
|
||||
in
|
||||
flake-parts.lib.mkFlake {inherit inputs;} {
|
||||
systems = [
|
||||
"aarch64-darwin"
|
||||
"x86_64-linux"
|
||||
"aarch64-linux"
|
||||
"x86_64-darwin"
|
||||
"x86_64-linux"
|
||||
"aarch64-darwin"
|
||||
];
|
||||
|
||||
perSystem = {
|
||||
pkgs,
|
||||
system,
|
||||
...
|
||||
}: let
|
||||
nixvim' = nixvim.legacyPackages."${system}";
|
||||
nvim = nixvim'.makeNixvim config;
|
||||
in {
|
||||
packages = {
|
||||
forAllSystems = nixpkgs.lib.genAttrs systems;
|
||||
in
|
||||
{
|
||||
packages = forAllSystems (
|
||||
system:
|
||||
let
|
||||
nixvim' = nixvim.legacyPackages.${system};
|
||||
nvim = nixvim'.makeNixvim config;
|
||||
in
|
||||
{
|
||||
inherit nvim;
|
||||
default = nvim;
|
||||
};
|
||||
};
|
||||
}
|
||||
);
|
||||
};
|
||||
}
|
||||
```
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue