Compare commits

..

2 commits

Author SHA1 Message Date
mae
30cc4f16e5 Add support for hexediting to nvim 2023-04-30 18:26:56 +02:00
mae
af53ec73c7 Update flake.lock 2023-04-29 22:48:48 +02:00
5 changed files with 46 additions and 22 deletions

View file

@ -191,11 +191,11 @@
"rust-analyzer-src": "rust-analyzer-src" "rust-analyzer-src": "rust-analyzer-src"
}, },
"locked": { "locked": {
"lastModified": 1682598812, "lastModified": 1682749232,
"narHash": "sha256-kNX5Au2i6ojBjBD5guay3qeHitm0vEhnnIvbv+BQoh8=", "narHash": "sha256-tZdhmgUIuSrRB8j1fTa5JVdewdNf0crNwDMnNIKfYqE=",
"owner": "nix-community", "owner": "nix-community",
"repo": "fenix", "repo": "fenix",
"rev": "b4616f7fa72bcda1b48511e4043d6813aa2d953b", "rev": "30d4a659367f2399cdc9e813c516ae53d46ab266",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -372,11 +372,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1682535786, "lastModified": 1682759296,
"narHash": "sha256-NH2a8yB8V25cglvcHDrvaTLvohzMgGLLZ4vnXQn4vOw=", "narHash": "sha256-FgBfP1e+TnED0lT3L9G6KJ6j07xQElFMRdLIsmKQ0Ss=",
"owner": "nix-community", "owner": "nix-community",
"repo": "home-manager", "repo": "home-manager",
"rev": "d82c9af8175878a461a0fdf914e67cc446664570", "rev": "27d89b49e3cd3c83b9609a6ff9173a9b8d2d9ad4",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -419,11 +419,11 @@
}, },
"latest_2": { "latest_2": {
"locked": { "locked": {
"lastModified": 1682609660, "lastModified": 1682764772,
"narHash": "sha256-Q2lncLCbUpFAs22n4NKjxt8hDsF4lCXq4lDjixjL0us=", "narHash": "sha256-PU1Til56N5L2SNHSbNavjzbDlYs5THfQqVjXtUpZHgM=",
"owner": "nixos", "owner": "nixos",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "76a85de7a731a037f44f1fcc81165c934c66b0a2", "rev": "0c97d307e68209414977ae270db9d9afafde21b6",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -478,11 +478,11 @@
}, },
"nixos": { "nixos": {
"locked": { "locked": {
"lastModified": 1682526928, "lastModified": 1682692304,
"narHash": "sha256-2cKh4O6t1rQ8Ok+v16URynmb0rV7oZPEbXkU0owNLQs=", "narHash": "sha256-9/lyXN2BpHw+1xE+D2ySBSLMCHWqiWu5tPHBMRDib8M=",
"owner": "nixos", "owner": "nixos",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "d6b863fd9b7bb962e6f9fdf292419a775e772891", "rev": "937a9d1ee7b1351d8c55fff6611a8edf6e7c1c37",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -509,11 +509,11 @@
}, },
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1682453498, "lastModified": 1682692304,
"narHash": "sha256-WoWiAd7KZt5Eh6n+qojcivaVpnXKqBsVgpixpV2L9CE=", "narHash": "sha256-9/lyXN2BpHw+1xE+D2ySBSLMCHWqiWu5tPHBMRDib8M=",
"owner": "nixos", "owner": "nixos",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "c8018361fa1d1650ee8d4b96294783cf564e8a7f", "rev": "937a9d1ee7b1351d8c55fff6611a8edf6e7c1c37",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -632,11 +632,11 @@
"rust-analyzer-src": { "rust-analyzer-src": {
"flake": false, "flake": false,
"locked": { "locked": {
"lastModified": 1682502267, "lastModified": 1682710505,
"narHash": "sha256-S1Rk8+lW6GqnfVDyxR7ctJaGRglvhm/DWCeDD3J3ut8=", "narHash": "sha256-03cthpkTbEdQF7wpmJjPuBvwcQ5eSV4jDfWj8Evg4Lk=",
"owner": "rust-lang", "owner": "rust-lang",
"repo": "rust-analyzer", "repo": "rust-analyzer",
"rev": "797c2f1dde0905afa24f567160ed23ba2bc79a81", "rev": "370b72c7dd3dcdb1efe92224ab1622e44639cb07",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -648,11 +648,11 @@
}, },
"stable": { "stable": {
"locked": { "locked": {
"lastModified": 1682538316, "lastModified": 1682669017,
"narHash": "sha256-YuHgVsR7S9zxJWHo7lo2ugd+uDC4ESWg1hA4bEZQv3Y=", "narHash": "sha256-Vi+p4y3wnl0/4gcwTdmCO398kKlDaUrNROtf3GOD2NY=",
"owner": "nixos", "owner": "nixos",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "15b75800dce80225b44f067c9012b09de37dfad2", "rev": "7449971a3ecf857b4a554cf79b1d9dcc1a4647d8",
"type": "github" "type": "github"
}, },
"original": { "original": {

View file

@ -2,7 +2,7 @@
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [
pavucontrol pavucontrol
signal-desktop signal-desktop
tdesktop telegram-desktop
firefox-wayland firefox-wayland
chromium chromium
nomacs nomacs

View file

@ -14,6 +14,7 @@ in
./clangd.nix ./clangd.nix
./elixir.nix ./elixir.nix
./dart.nix ./dart.nix
./hexeditor.nix
]; ];
options.mae.nvim = { options.mae.nvim = {

View file

@ -0,0 +1,22 @@
{ lib, pkgs, config, ... }:
let
cfg = config.mae.nvim.hexeditor;
in
{
options.mae.nvim.hexeditor.enable = lib.mkEnableOption "Enable hexediting in neovim";
config = lib.mkIf cfg.enable {
programs.neovim.extraConfig = ''
augroup Binary
au!
au BufReadPre *.bin let &bin=1
au BufReadPost *.bin if &bin | %!xxd
au BufReadPost *.bin set ft=xxd | endif
au BufWritePre *.bin if &bin | %!xxd -r
au BufWritePre *.bin endif
au BufWritePost *.bin if &bin | %!xxd
au BufWritePost *.bin set nomod | endif
augroup END
'';
};
}

View file

@ -12,5 +12,6 @@
python.enable = true; python.enable = true;
elixir.enable = true; elixir.enable = true;
dart.enable = true; dart.enable = true;
hexeditor.enable = true;
}; };
} }