add nnn overlay

This commit is contained in:
Tyler Starr 2023-07-11 21:17:48 -07:00
parent d17c974a47
commit c541db90ff
19 changed files with 68 additions and 220 deletions

View File

@ -17,6 +17,7 @@ desktop_file() {
find "$HOME/.local/share/applications" -name "*.desktop"
find /var/lib/flatpak/exports/share/applications -name "*.desktop"
find "$HOME/.local/share/flatpak/exports/share/applications" -name "*.desktop"
find /run/current-system/sw/share/applications -name "*.desktop"
}
selected="$(desktop_file | sed 's/.desktop//g' | sort | fzf -e -i -m --reverse --delimiter / --with-nth -1)"

View File

@ -0,0 +1,11 @@
local wk = require("which-key")
wk.register({
-- nnn and netrw commands
n = {
name = "+nnn",
n = { "<cmd>NnnPicker<CR>", "NNN Picker" },
e = { "<cmd>NnnExplorer<CR>", "NNN Explorer" },
v = { "<cmd>Ex<CR>", "Netrw Explorer" }
},
}, { prefix = "<leader>" })

View File

@ -1,11 +1,6 @@
local wk = require("which-key")
wk.register({
-- netrw commands
n = {
name = "+netrw",
v = { "<cmd>Ex<CR>", "Explorer" }
},
-- tab commands
t = {
name = "+tab",

View File

@ -4,5 +4,3 @@ require("tstarr.telescope")
require("tstarr.vimwiki")
require("tstarr.which-key")
require("tstarr.iron")
require("tstarr.nvim-tree")
--require("tstarr.neorg")

View File

@ -1,16 +0,0 @@
-- empty setup using defaults
require("nvim-tree").setup()
-- OR setup with some options
require("nvim-tree").setup({
sort_by = "case_sensitive",
view = {
width = 30,
},
renderer = {
group_empty = true,
},
filters = {
dotfiles = true,
},
})

View File

@ -46,6 +46,5 @@ return require('packer').startup(function(use)
use('loctvl842/monokai-pro.nvim')
require("monokai-pro").setup()
use('nvim-tree/nvim-tree.lua')
use('mcchrish/nnn.vim')
end)

View File

@ -1,20 +1,5 @@
{
"nodes": {
"flake-utils": {
"locked": {
"lastModified": 1642700792,
"narHash": "sha256-XqHrk7hFb+zBvRg6Ghl+AZDq03ov6OshJLiSWOoX5es=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "846b2ae0fc4cc943637d3d1def4454213e203cba",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"home-manager": {
"inputs": {
"nixpkgs": [
@ -22,77 +7,39 @@
]
},
"locked": {
"lastModified": 1683989410,
"narHash": "sha256-puF/QsIkp4ch0sf6M5mNzbdZtYcq2MJHcKre9wJ3ZYo=",
"lastModified": 1687871164,
"narHash": "sha256-bBFlPthuYX322xOlpJvkjUBz0C+MOBjZdDOOJJ+G2jU=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "6702b22b9805bc1879715d4111e3764cd4237aed",
"rev": "07c347bb50994691d7b0095f45ebd8838cf6bc38",
"type": "github"
},
"original": {
"owner": "nix-community",
"ref": "release-23.05",
"repo": "home-manager",
"type": "github"
}
},
"mach-nix": {
"inputs": {
"flake-utils": "flake-utils",
"nixpkgs": [
"nixpkgs"
],
"pypi-deps-db": "pypi-deps-db"
},
"locked": {
"lastModified": 1681814846,
"narHash": "sha256-IMQ1Twf/ozE53CwrunXNlYD3D31xqgz/mZyZG38Ov/Y=",
"owner": "DavHau",
"repo": "mach-nix",
"rev": "8d903072c7b5426d90bc42a008242c76590af916",
"type": "github"
},
"original": {
"owner": "DavHau",
"repo": "mach-nix",
"type": "github"
}
},
"nixpkgs": {
"locked": {
"lastModified": 1683408522,
"narHash": "sha256-9kcPh6Uxo17a3kK3XCHhcWiV1Yu1kYj22RHiymUhMkU=",
"lastModified": 1688939073,
"narHash": "sha256-jYhYjeK5s6k8QS3i+ovq9VZqBJaWbxm7awTKNhHL9d0=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "897876e4c484f1e8f92009fd11b7d988a121a4e7",
"rev": "8df7a67abaf8aefc8a2839e0b48f92fdcf69a38b",
"type": "github"
},
"original": {
"owner": "nixos",
"ref": "nixos-unstable",
"ref": "nixos-23.05",
"repo": "nixpkgs",
"type": "github"
}
},
"pypi-deps-db": {
"flake": false,
"locked": {
"lastModified": 1678051695,
"narHash": "sha256-kFFP8TN8pEKARtjK9loGdH+TU23ZbHdVLCUdNcufKPs=",
"owner": "DavHau",
"repo": "pypi-deps-db",
"rev": "e00b22ead9d3534ba1c448e1af3076af6b234acf",
"type": "github"
},
"original": {
"owner": "DavHau",
"repo": "pypi-deps-db",
"type": "github"
}
},
"root": {
"inputs": {
"home-manager": "home-manager",
"mach-nix": "mach-nix",
"nixpkgs": "nixpkgs"
}
}

View File

@ -2,18 +2,14 @@
description = "A very basic flake";
inputs = {
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
nixpkgs.url = "github:nixos/nixpkgs/nixos-23.05";
home-manager = {
url = github:nix-community/home-manager;
url = github:nix-community/home-manager/release-23.05;
inputs.nixpkgs.follows = "nixpkgs";
};
mach-nix= {
url = "github:DavHau/mach-nix";
inputs.nixpkgs.follows = "nixpkgs";
};
};
outputs = inputs @ { self, nixpkgs, home-manager, mach-nix, ... }:
outputs = inputs @ { self, nixpkgs, home-manager, ... }:
let
system = "x86_64-linux";
pkgs = import nixpkgs {

View File

@ -38,27 +38,6 @@
time.timeZone = "America/Los_Angeles";
i18n.defaultLocale = "en_US.UTF-8";
#services.xserver = {
# enable = true;
# layout = "us";
# desktopManager.xterm.enable = false;
# # Use nvidia drivers
# videoDrivers = [ "amdgpu" ];
# displayManager.gdm.enable = true;
# desktopManager.gnome.enable = true;
# # Use the xmonad wm
# windowManager = {
# xmonad = {
# enable = true;
# enableContribAndExtras = true;
# };
# };
#};
# Enable sound.
sound.enable = true;
hardware.pulseaudio.enable = true;
@ -69,10 +48,14 @@
nerdfonts
];
# Enable virtualisation
virtualisation.docker.enable = true;
virtualisation.docker.storageDriver = "btrfs";
# Enable zsh
programs.zsh.enable = true;
# Define a user account. Don't forget to set a password with passwd.
# Define user account.
users.users.${user} = {
isNormalUser = true;
extraGroups = [ "wheel" "docker" ]; # Enable sudo for the user.
@ -87,13 +70,10 @@
killall
pciutils
syncthing
#pamixer
vifm
mpv
pinentry-curses
trash-cli
bc
unzip
nnn
];
# Enable user services
@ -106,9 +86,9 @@
avahi.nssmdns = true;
syncthing = {
enable = true;
user = "tstarr";
dataDir = "/home/tstarr/sync";
configDir = "/home/tstarr/.config/syncthing";
user = "${user}";
dataDir = "/home/${user}/sync";
configDir = "/home/${user}/.config/syncthing";
};
};
@ -126,7 +106,6 @@
modules = {
services = {
samba.enable = true;
vfio.enable = false; # Currently broken
};
devel = {
tooling.enable = true;
@ -141,5 +120,5 @@
};
};
system.stateVersion = "22.11"; # Did you read the comment?
system.stateVersion = "23.05"; # Did you read the comment?
}

View File

@ -14,43 +14,41 @@
boot.extraModulePackages = [ ];
fileSystems."/" =
{ device = "/dev/disk/by-uuid/b946d3b5-86ea-4f22-be13-532a60023b98";
{ device = "/dev/disk/by-uuid/873ccce0-c706-4ef4-b7d1-748e93e54aae";
fsType = "btrfs";
options = [ "subvol=root" ];
};
fileSystems."/home" =
{ device = "/dev/disk/by-uuid/b946d3b5-86ea-4f22-be13-532a60023b98";
{ device = "/dev/disk/by-uuid/873ccce0-c706-4ef4-b7d1-748e93e54aae";
fsType = "btrfs";
options = [ "subvol=home" ];
};
fileSystems."/nix" =
{ device = "/dev/disk/by-uuid/b946d3b5-86ea-4f22-be13-532a60023b98";
{ device = "/dev/disk/by-uuid/873ccce0-c706-4ef4-b7d1-748e93e54aae";
fsType = "btrfs";
options = [ "subvol=nix" ];
};
fileSystems."/persist" =
{ device = "/dev/disk/by-uuid/b946d3b5-86ea-4f22-be13-532a60023b98";
{ device = "/dev/disk/by-uuid/873ccce0-c706-4ef4-b7d1-748e93e54aae";
fsType = "btrfs";
options = [ "subvol=persist" ];
};
fileSystems."/var/log" =
{ device = "/dev/disk/by-uuid/b946d3b5-86ea-4f22-be13-532a60023b98";
{ device = "/dev/disk/by-uuid/873ccce0-c706-4ef4-b7d1-748e93e54aae";
fsType = "btrfs";
options = [ "subvol=log" ];
};
fileSystems."/boot" =
{ device = "/dev/disk/by-uuid/0A89-7181";
{ device = "/dev/disk/by-uuid/37EE-81E0";
fsType = "vfat";
};
swapDevices =
[ { device = "/dev/disk/by-uuid/b62ff9a9-37ed-494a-9805-9f148aff4b9c"; }
];
swapDevices = [ ];
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
# (the default) this is the recommended approach. When using systemd-networkd it's

View File

@ -4,21 +4,10 @@
home.homeDirectory = "/home/${user}";
programs.home-manager.enable = true;
home.packages = with pkgs; [
google-chrome
firefox
alacritty
gamemode
lutris
pcmanfm
discord
inkscape
libreoffice-fresh
chezmoi
rbw
vscodium.fhs
];
home.stateVersion = "22.11";
home.stateVersion = "23.05";
}

View File

@ -28,7 +28,15 @@ in {
config = lib.mkIf cfg.enable {
environment.systemPackages = with pkgs; [
alacritty
sway
swayidle
swaybg
grim # screenshot functionality
wl-clipboard # wl-copy and wl-paste for copy/paste from stdin / stdout
mako # notification system developed by swaywm maintainer
wdisplays # tool to configure displays
playerctl
wayland
xwayland
configure-gtk
@ -36,16 +44,18 @@ in {
glib # gsettings
dracula-theme # gtk theme
gnome3.adwaita-icon-theme # default gnome cursors
swaylock-effects
swayidle
grim # screenshot functionality
wl-clipboard # wl-copy and wl-paste for copy/paste from stdin / stdout
mako # notification system developed by swaywm maintainer
#dunst
wdisplays # tool to configure displays
rofi
imagemagick
feh
bc
fzf
# From home config
pcmanfm
google-chrome
firefox
gamemode
discord
inkscape
libreoffice-fresh
mpv
];
# xdg-desktop-portal works by exposing a series of D-Bus interfaces

View File

@ -13,7 +13,7 @@ in {
neovim
ripgrep
tmux
tmuxinator
tmuxp
];
};
}

View File

@ -16,7 +16,7 @@ in {
environment.systemPackages = [
pkgs.steam
pkgs.ryujinx
pkgs.yuzu-early-access
];
};

View File

@ -1,5 +1,4 @@
{ ... }:
{
imports = [ ./samba.nix ./vfio.nix ];
imports = [ ./samba.nix ];
}

View File

@ -1,57 +0,0 @@
# vfio setup for windows gaming with single gpu
{ config, lib, pkgs, user, ... }:
let cfg = config.modules.services.vfio;
in {
options.modules.services.vfio.enable = lib.mkEnableOption "samba";
config = lib.mkIf cfg.enable {
users.users.${user}.extraGroups = [ "qemu-libvirtd" "libvirtd" "kvm" ];
# Boot configuration
boot.kernelParams = [ "amd_iommu=on" "iommu=pt" ];
boot.kernelModules = [ "kvm-amd" "vfio-pci" ];
programs.dconf.enable = true;
environment.systemPackages = with pkgs; [ virt-manager ];
# Enable libvirtd
virtualisation.libvirtd = {
enable = true;
onBoot = "ignore";
onShutdown = "shutdown";
qemu.ovmf.enable = true;
qemu.runAsRoot = true;
};
# Place helper files where libvirt can get to them
environment.etc = {
"libvirt/hooks/qemu" = {
source = "/home/${user}/.setup/local/gpu-passthrough/qemu";
mode = "0755";
};
"libvirt/hooks/qemu.d/win10/prepare/begin/start.sh" = {
source = "/home/${user}/.setup/local/gpu-passthrough/start.sh";
mode = "0755";
};
"libvirt/hooks/qemu.d/win10/release/end/revert.sh" = {
source = "/home/${user}/.setup/local/gpu-passthrough/revert.sh";
mode = "0755";
};
"libvirt/qemu.conf" = {
source = "/home/${user}/.setup/local/gpu-passthrough/qemu.conf";
mode = "0755";
};
"libvirt/libvirtd.conf" = {
source = "/home/${user}/.setup/local/gpu-passthrough/libvirtd.conf";
mode = "0755";
};
"libvirt/patch.rom" = {
source = "/home/${user}/.setup/local/gpu-passthrough/patch.rom";
mode = "0755";
};
};
};
}

View File

@ -0,0 +1 @@

View File

@ -0,0 +1,3 @@
self: super: {
nnn = super.nnn.override { withNerdIcons = true; };
}

View File

@ -1,5 +0,0 @@
self: super: {
rofi = super.rofi.override { plugins = [ self.rofi-emoji ]; };
}