Skip to content

language/docker: init#1431

Draft
snoweuph wants to merge 1 commit intoNotAShelf:mainfrom
snoweuph:feat/docker
Draft

language/docker: init#1431
snoweuph wants to merge 1 commit intoNotAShelf:mainfrom
snoweuph:feat/docker

Conversation

@snoweuph
Copy link
Copy Markdown
Collaborator

@snoweuph snoweuph commented Feb 27, 2026

Adds support for docker, docker compose and also docker in terraform.

most if it was already created in #1104.

Sanity Checking

  • I have updated the changelog as per my changes
  • I have tested, and self-reviewed my code
  • My changes fit guidelines found in hacking nvf
  • Style and consistency
    • I ran Alejandra to format my code (nix fmt)
    • My code conforms to the editorconfig configuration of the project
    • My changes are consistent with the rest of the codebase
  • If new changes are particularly complex:
    • My code includes comments in particularly complex areas
    • I have added a section in the manual
    • (For breaking changes) I have included a migration guide
  • Package(s) built:
    • .#nix (default package)
    • .#maximal
    • .#docs-html (manual, must build)
    • .#docs-linkcheck (optional, please build if adding links)
  • Tested on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin

Add a 👍 reaction to pull requests you find important.

];
filetypes = [
"dockerfile"
"dockercompose"
Copy link
Copy Markdown
Collaborator Author

@snoweuph snoweuph Feb 27, 2026

Choose a reason for hiding this comment

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

like we talked about on matrix:

Note

As soon as we have the new filetype API (#1365),
turn all (docker-)?compose\.ya?ml into the filetype dockercompose otherwise the LSP is to stupid...

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

I could write an autocommand for this :copium:

inherit (lib.nvim.types) mkGrammarOption diagnostics;
inherit (lib.nvim.attrsets) mapListToAttrs;

cfg = config.vim.languages.docker;
Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Still open for discussion if this should be a languages.docker which has the YAML and HCL support, or if it should be languages.dockerfile and YAML and HCL support should be moved into the respective modules.

github-actions bot pushed a commit that referenced this pull request Feb 27, 2026
@github-actions
Copy link
Copy Markdown

github-actions bot commented Feb 27, 2026

🚀 Live preview deployed from 4f10740

View it here:

Debug Information

Triggered by: snoweuph

HEAD at: feat/docker

Reruns: 2364

@snoweuph snoweuph force-pushed the feat/docker branch 2 times, most recently from 3b5abee to c6cdb87 Compare February 27, 2026 20:19
@snoweuph
Copy link
Copy Markdown
Collaborator Author

rebased for my sanity

github-actions bot pushed a commit that referenced this pull request Mar 21, 2026
github-actions bot pushed a commit that referenced this pull request Mar 21, 2026
@snoweuph snoweuph added the TBD More discussion and research is in order label Mar 28, 2026
@snoweuph
Copy link
Copy Markdown
Collaborator Author

snoweuph commented Mar 29, 2026

I'm already using this in my nvf based config:

But as this requires a ftdetect to work correctly, this wont get merged any time soon, because we don't include those in nvf, but there is work on an new API for exactly this in: #1365.
till then I will rebase this from time to time...

So for anybody that wants docker support in their config, feel free to steal my config, as long as you're human.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant