Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

experimental configuration-based nixvim template #2854

Merged
merged 2 commits into from
Jan 21, 2025

Conversation

MattSturgeon
Copy link
Member

@MattSturgeon MattSturgeon commented Jan 18, 2025

Adds an experimental flake template that configures Nixvim directly using evalNixvim rather than the current standalone functions.

Related issues

Real world usage

Todo

Since this is experimental/draft, we don't need to tick off everything above before merging.

@MattSturgeon MattSturgeon force-pushed the template/evalNixvim branch 2 times, most recently from 46cca53 to b92e08c Compare January 18, 2025 08:39
@MattSturgeon MattSturgeon force-pushed the template/evalNixvim branch 2 times, most recently from 50a7d65 to 94fd1ae Compare January 18, 2025 10:20
@GaetanLepage
Copy link
Member

This looks very promising !

@traxys

This comment has been minimized.

@MattSturgeon

This comment was marked as resolved.

@MattSturgeon MattSturgeon force-pushed the template/evalNixvim branch 2 times, most recently from d42ee40 to 88f5e37 Compare January 19, 2025 19:11
Copy link
Member

@traxys traxys left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a MUCH cleaner way to handle standalone modules!
It should also be much simpler to have a flake which uses standalone modules for rapid iteration & and exposes neovim through an home manager module with this kind of architecture

flake/flake-modules/auto.nix Outdated Show resolved Hide resolved
Copy link
Contributor

@khaneliman khaneliman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm really liking this. Right now my standalone setup feels hacky for creating the actual package output and this keeps it all modules and configuration without worrying about the flake output aspect, as much.

templates/new/flake.nix Outdated Show resolved Hide resolved
flake/templates.nix Outdated Show resolved Hide resolved
This template uses the lower-level `evalNixvim` function to work
directly with nixvim configurations, instead of the prior idiom of using
`makeNixvim` to produce nixvim packages.

Additionally, the template is build on flake.parts, and demonstrates
using our recently added flakeModules.
Copy link
Member

@traxys traxys left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not too concerned about the name personally.

We should figure out a way to document the templates, maybe by adding their README to sections in the main book

@MattSturgeon
Copy link
Member Author

@mergify queue

Copy link
Contributor

mergify bot commented Jan 21, 2025

queue

✅ The pull request has been merged automatically

The pull request has been merged automatically at 342161b

Copy link
Contributor

mergify bot commented Jan 21, 2025

This pull request, with head sha 342161bf525dd64eb53fea295a2180f71ed06de1, has been successfully merged with fast-forward by Mergify.

This pull request will be automatically closed by GitHub.

As soon as GitHub detects that the sha 342161bf525dd64eb53fea295a2180f71ed06de1 is part of the main branch, it will mark this pull request as merged.

It is possible for this pull request to remain open if this detection does not happen, this usually happens when a force-push is done on this branch template/evalNixvim, this means GitHub will fail to detect the merge.

@mergify mergify bot merged commit 342161b into nix-community:main Jan 21, 2025
4 checks passed
@mergify mergify bot temporarily deployed to github-pages January 21, 2025 20:14 Inactive
@MattSturgeon MattSturgeon deleted the template/evalNixvim branch January 21, 2025 20:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants