Skip to content

languages/nix: remove hardcoded indentation options#567

Merged
NotAShelf merged 2 commits intomainfrom
no-buffer-specific-opts
Jan 18, 2025
Merged

languages/nix: remove hardcoded indentation options#567
NotAShelf merged 2 commits intomainfrom
no-buffer-specific-opts

Conversation

@NotAShelf
Copy link
Owner

Removes the hardcoded 2-wide indentation from Nix filetype. To replicate previous behaviour, user must consolidate indentation behaviour to the Editorconfig configuration, or use autocommands in raw lua configuration.

Example:

vim.api.nvim_create_autocmd("FileType", {
  pattern = "nix",
  callback = function(opts)
  	local bo = vim.bo[opts.buf]
  	bo.tabstop = 2
  	bo.shiftwidth = 2
  end
 })

While feedback for this "sane" default has been mostly positive, nvf has no place setting opinionated defaults that are difficult to override. Fixes #564

github-actions bot pushed a commit that referenced this pull request Jan 18, 2025
@github-actions
Copy link

github-actions bot commented Jan 18, 2025

🚀 Live preview deployed from e51dce0

View it here:

Debug Information

Triggered by: NotAShelf

HEAD at: no-buffer-specific-opts

Reruns: 82

@diniamo diniamo force-pushed the no-buffer-specific-opts branch from bb0a857 to 7d0c56d Compare January 18, 2025 17:55
@NotAShelf NotAShelf merged commit e51dce0 into main Jan 18, 2025
14 checks passed
@NotAShelf NotAShelf deleted the no-buffer-specific-opts branch January 18, 2025 18:00
@github-actions
Copy link

✅ Preview has been deleted successfully!

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.

Hard-coded buffer options when language is enabled.

2 participants