From c2affb9945e39ba116120338bfd640b694eb4ded Mon Sep 17 00:00:00 2001 From: NotAShelf Date: Mon, 6 Feb 2023 05:27:15 +0300 Subject: [PATCH] docs: update readme & style --- README.md | 117 ++++++++++++++++++++++++++++----- docs/custom-configs.adoc | 2 +- docs/default-configs.adoc | 6 +- docs/release-notes/rl-0.2.adoc | 31 +++++++++ 4 files changed, 136 insertions(+), 20 deletions(-) create mode 100644 docs/release-notes/rl-0.2.adoc diff --git a/README.md b/README.md index ba7228c..a3030a5 100644 --- a/README.md +++ b/README.md @@ -1,17 +1,90 @@ -# neovim-flake +

+ + Latest release + + + License + + + Stars + + + Issues + + + Repo Size + -A highly configurable nix flake for neovim, packing everything you might need to create your own neovim IDE. + +

+ +

+ +An Nix wrapped IDE layer for the superior text editor, Neovim. + +--- + +**[
 Install 
][Install]**  +**[
 Configure 
][Configure]**  +**[
 Documentation 
][Documentation]**  +**[
 Contribute 
][Contribute]** +**[
 FAQ 
][Faq]** + +--- + +A highly configurable nix flake for Neovim, packing everything you might need to create your own neovim IDE. + +## Install + +**Using `nix`** + +The easiest way to install is to use the `nix profile` command. To install the default configuration, run: + +```console +nix run github:notashelf/neovim-flake +``` +The package exposes `.#nix` as the default output. You may use `.#nix`, `.#tidal` or `.#maximal` to get different configurations. + +It is as simply as changing the target output to get a different configuration. For example, to get a configuration with `tidal` support, run: + +```console +nix run github:notashelf/neovim-flake#tidal +``` + +Similar instructions will apply for `nix profile install`. + +**On NixOS** + +NixOS users may add this repo to their flake inputs as such: + +```nix +{ + inputs = { + # point at this repository, you may pin specific revisions or branches while using `github:` + neovim-flake.url = "github:notashelf/neovim-flake"; + + # you may override our nixpkgs with your own, this will save you some cache hits and s recommended + nixpkgs.follows = "nixpkgs"; + }; +} +``` + +Then, you can use the `neovim-flake` input in your `systemPackages` or `home.packages`. + +## Configure + +TODO (awaiting #1 to be merged, which implements a separate configuration file) ## Documentation -See the [neovim-flake Manual](https://notashelf.github.io/neovim-flake/) for documentation, available options, and release notes. -If you want to dive right into trying neovim-flake you can get a fully featured configuration with `nix` language support by running: +See the [neovim-flake Manual](https://notashelf.github.io/neovim-flake/) for detailed documentation, available options, and release notes. +If you want to dive right into trying **neovim-flake** you can get a fully featured configuration with `nix` language support by running: ```console nix run github:notashelf/neovim-flake ``` -The documentation is scarce right now as a result of the ongoing rebase and refactor, but shall be available once more soon. +The documentation is scarce right now as a result of the ongoing rebase and refactor, but shall be available once more soon. ## Help @@ -19,24 +92,36 @@ You can create an issue on the [issue tracker](issues) to ask questions or repor ## Philosophy -The philosophy behind this flake configuration is to create an eaesily configurable and reproducible neovim environment. While it does sacrifice in size -(which I know some users will find *disagreeable*), it offers a lot of flexibiity and configurability in exchange for the large size of the flake inputs. -The KISS (Keep it simple, stupid) principle has been abandoneed here, but you can ultimately declare a configuration that follows KISS. -For it is very easy to bring your own plugins and configurations. Whether you are a developer, writer, or live coder (see tidal cycles below!), -quickly craft a config that suits every project's need. Think of it like a distribution of Neovim that takes advantage of pinning vim plugins and +The philosophy behind this flake configuration is to create an easily configurable and reproducible Neovim environment. While it does sacrifice in size +(which I know some users will find *disagreeable*), it offers a lot of flexibility and customizability in exchange for the large size of the flake inputs. +The KISS (Keep it simple, stupid) principle has been abandoned here, but you can ultimately declare a configuration that follows KISS. +For it is very easy to bring your own plugins and configurations. Whether you are a developer, writer, or live coder (see tidal cycles below!), +quickly craft a config that suits every project's need. Think of it like a distribution of Neovim that takes advantage of pinning vim plugins and third party dependencies (such as tree-sitter grammars, language servers, and more). -One should never get a broken config when setting options. If setting multiple options results in a broken neovim, file an issue! Each plugin knows when another plugin which allows for smart configuration of keybindings and automatic setup of things like completion sources and languages. +One should never get a broken config when setting options. If setting multiple options results in a broken Neovim, file an issue! Each plugin knows when another plugin which allows for smart configuration of keybindings and automatic setup of things like completion sources and languages. ## Credits This configuration is based on a few other configurations, including: -- @sioodmy's [dotfiles](https://github.com/sioodmy/dotfiles) -- @wiltaylor's [neovim-flake](https://github.com/wiltaylor/neovim-flake) -- @jordanisaacs's [neovim-flake](https://github.com/jordanisaacs/neovim-flake) -- @gvolpe's [neovim-flake](https://github.com/gvolpe/neovim-flake) +- [@sioodmy's](https://github.com/sioodmy) [dotfiles](https://github.com/sioodmy/dotfiles) +- [@wiltaylor's](https://github.com/wiltaylor) [neovim-flake](https://github.com/wiltaylor/neovim-flake) +- [@jordanisaacs's](https://github.com/jordanisaacs) [neovim-flake](https://github.com/jordanisaacs/neovim-flake) +- [@gvolpe's](https://github.com/gvolpe) [neovim-flake](https://github.com/gvolpe/neovim-flake) I am grateful for their work and inspiration. ---- +## FAQ + +**Q**: Why is this flake so big? + +**A**: I have sacrificed in size in order to provide a highly configurable and reproducible Neovim environment. A binary cache is provided to +eleminate the need to build the flake from source, but it is still a large flake. If you do not need all the features, you can use the default `nix` output +instead of the `maximal` output. This will reduce size by a lot, but you will lose some language specific features. + +**Q**: Will you use a plugin manager? + +**A**: No. If you feel the need to ask that question, then you have missed the whole point of using nix and ultimately this flake. We load plugins with raw lua. + +--- diff --git a/docs/custom-configs.adoc b/docs/custom-configs.adoc index 17994f7..74417cb 100644 --- a/docs/custom-configs.adoc +++ b/docs/custom-configs.adoc @@ -18,7 +18,7 @@ The following is an example of a barebones vim configuration with the default th [source,nix] ---- { - inputs.neovim-flake.url = "github:jordanisaacs/neovim-flake"; + inputs.neovim-flake.url = "github:notashelf/neovim-flake"; outputs = {nixpkgs, neovim-flake, ...}: let system = "x86_64-linux"; diff --git a/docs/default-configs.adoc b/docs/default-configs.adoc index 1a8f0f6..981d859 100644 --- a/docs/default-configs.adoc +++ b/docs/default-configs.adoc @@ -7,7 +7,7 @@ While you can configure neovim-flake yourself using the builder, here are a few === Tidal Cycles [source,console] -$ nix run github:jordanisaacs/neovim-flake#tidal file.tidal +$ nix run github:notashelf/neovim-flake#tidal file.tidal Utilizing https://github.com/tidalcycles/vim-tidal[vim-tidal] and mitchmindtree's fantastic https://github.com/mitchmindtree/tidalcycles.nix[tidalcycles.nix] start playing with tidal cycles in a single command. @@ -18,7 +18,7 @@ In your tidal file, type a cycle e.g. `d1 $ s "drum"` and then press _ctrl+enter === Nix [source,console] -$ nix run github:jordanisaacs/neovim-flake#nix test.nix +$ nix run github:notashelf/neovim-flake#nix test.nix Enables all the of neovim plugins, with language support for specifically Nix. This lets you see what a fully configured neovim setup looks like without downloading a whole bunch of language servers and associated tools. @@ -26,7 +26,7 @@ Enables all the of neovim plugins, with language support for specifically Nix. T === Maximal [source,console] -$ nix shell github:jordanisaacs/neovim-flake#maximal test.nix +$ nix shell github:notashelf/neovim-flake#maximal test.nix It is the same fully configured neovim as with the <> config, but with every supported language enabled. diff --git a/docs/release-notes/rl-0.2.adoc b/docs/release-notes/rl-0.2.adoc new file mode 100644 index 0000000..ff9fdc3 --- /dev/null +++ b/docs/release-notes/rl-0.2.adoc @@ -0,0 +1,31 @@ +[[sec-release-0.2]] +== Release 0.2 + +Release notes for release 0.2 + + +[[sec-release-0.1-changelog]] +=== Changelog + +https://github.com/notashelf[notashelf]: + +* Added minimap options under `vim.minimap`. The default will be codewindow.nvim. + +* Removed hare language support (lsp/tree-sitter/etc). `vim.lsp.hare` is no longer defined. If you use hare and would like it added back, please file an issue. + +* <> & <> are now an enum of `string` for options sourced from the flake inputs. Users can still provide vim plugin packages. ++ +If you are contributing and adding a new plugin, add the plugin name to `availablePlugins` in https://github.com/jordanisaacs/neovim-flake/blob/20cec032bd74bc3d20ac17ce36cd84786a04fd3e/modules/lib/types-plugin.nix[types-plugin.nix]. + +* `neovimBuilder` has been removed for configuration. Using an overlay is no longer required. See the manual for the new way to configuration. + +* Treesitter grammars are now configurable with <>. Utilizes the nixpkgs `nvim-treesitter` plugin rather than a custom input in order to take advantage of build support of pinned versions. See https://discourse.nixos.org/t/psa-if-you-are-on-unstable-try-out-nvim-treesitter-withallgrammars/23321?u=snowytrees[discourse] for more information. Packages can be found under the `vimPlugins.nvim-treesitter.builtGrammars` namespace. + +* <> and <> are now of type DAG lines. This allows for ordering of the config. Usage is the same is in home-manager's `home.activation` option. ++ +[source,nix] +---- +vim.luaConfigRC = lib.nvim.dag.entryAnywhere "config here" +---- + +