Browse Source

cue: Added cue-lang support

pull/1/head
Craige McWhirter 1 year ago
parent
commit
a7c782e03a
Signed by: craige
GPG Key ID: 7DBA9F5689EFB6AA
  1. 17
      overlays/vim-cue.nix
  2. 1
      profiles/iohk.nix
  3. 12
      profiles/vim.nix

17
overlays/vim-cue.nix

@ -0,0 +1,17 @@
# Cue filetype plugin for Vim
#
# Provide an overlay to obtain vim-cue from upstream rather than nixpkgs
final: prev: {
vimPlugins = prev.vimPlugins // {
vim-cue = prev.vimUtils.buildVimPlugin {
name = "vim-cue";
src = prev.fetchFromGitHub {
owner = "jjo";
repo = "vim-cue";
rev = "9e8bef1198817b6bae1143fecd965403d65d2466";
sha256 = "sha256-VEJh3u2s4Ccc/JQa383FDcurCgUiNFlEuqXXhO0nB2c=";
};
};
};
}

1
profiles/iohk.nix

@ -30,6 +30,7 @@
systemPackages = with pkgs; [
awscli # Unified tool to manage your AWS services
buildkite-agent # Buildkite for IOHK
cue # A data constraint language
docker # Pack, ship and run any application as a lightweight container
docker-compose # Multi-container orchestration for Docker
freerdp # A Remote Desktop Protocol Client, xfreerdp

12
profiles/vim.nix

@ -1,4 +1,4 @@
with import <nixpkgs> {};
with import <nixpkgs> { overlays = [ (import ../overlays/vim-cue.nix) ]; };
vim_configurable.customize {
name = "vim"; # Specifies the vim binary name.
@ -152,6 +152,15 @@ vim_configurable.customize {
endfunction
autocmd BufNewFile,BufFilePre,BufRead *.nix :call NixSettings()
" Settings for my Cue environment:
function! CueSettings()
set tabstop=2
set shiftwidth=2
set textwidth=79
let g:cue_fmt_on_save = 1
endfunction
autocmd BufNewFile,BufFilePre,BufRead *.cue :call CueSettings()
" Settings for my Crystal environment:
function! CrystalSettings()
set tabstop=2
@ -254,6 +263,7 @@ vim_configurable.customize {
tabular # Script for text filtering and alignment
vim-airline-themes # Collection of themes for airline
vim-colorschemes # Collection of ViM colour schemes
vim-cue # Cue filetype plugin for Vim
vim-nix # Support for writing Nix expressions in vim
vim-addon-nix # Scripts assisting writing .nix files
vim-polyglot # A solid language pack for Vim

Loading…
Cancel
Save