moved to neovim

This commit is contained in:
ISnortPennies 2022-08-09 16:42:45 -04:00 committed by ISnortPennies
parent 8e626d25e7
commit 2d60e04682
20 changed files with 147 additions and 103 deletions

2
.gitignore vendored Normal file
View file

@ -0,0 +1,2 @@
flake.lock
hardware-configuration.nix

View file

@ -1 +1,65 @@
# intentionally empty
{ config, pkgs, lib, ... }:
{
system.stateVersion = "22.11";
boot.kernelPackages = pkgs.linuxPackages_latest;
environment = {
defaultPackages = [];
binsh = "${pkgs.dash}/bin/dash";
variables = {
EDITOR = "nvim";
};
};
nix = {
package = pkgs.nixFlakes;
settings.auto-optimise-store = true;
extraOptions = ''
experimental-features = nix-command flakes
'';
};
networking = {
firewall.enable = true;
firewall.allowPing = true;
useDHCP = lib.mkDefault true;
networkmanager.enable = true;
};
qt5 = {
enable = true;
style = "gtk2";
platformTheme = "gtk2";
};
programs.dconf.enable = true;
time.timeZone = "America/New_York";
services = {
timesyncd = {
enable = true;
servers = [
"time.google.com"
"time2.google.com"
];
};
};
# Select internationalisation properties.
i18n.defaultLocale = "en_US.UTF-8";
console = {
font = "Lat2-Terminus16";
useXkbConfig = true;
};
# Enable sound.
security.rtkit.enable = true;
hardware.pulseaudio = {
enable = true;
support32Bit = true;
package = pkgs.pulseaudioFull;
};
#enable ssh
programs = {
mtr.enable = true;
gnupg.agent = {
enable = true;
enableSSHSupport = true;
};
};
services.openssh.enable = true;
}

View file

@ -13,13 +13,14 @@
inherit system;
config = {
allowUnfree = true;
pulseaudio = true;
packageOverrides = super: let self = super.pkgs; in {
#more overrides can go here
polkit_fix = self.polkit_gnome.overrideAttrs ( oldAttrs: rec
{
postInstall = ''
mkdir $out/bin
ln -s $out/libexec/polkit-gnome-authentication-agent-1 $out/bin/polkit-gnome-authentication-agent-1
ln -s $out/libexec/polkit-gnome-authentication-agent-1 $out/bin/polkit-gnome
'';
});
nerdfonts-overpass = self.nerdfonts.override {
@ -42,6 +43,7 @@
gerg-laptop = lib.nixosSystem {
inherit system pkgs;
modules = [
./configuration.nix
./hardware-configuration.nix
./systems/laptop.nix
];
@ -49,6 +51,7 @@
gerg-desktop = lib.nixosSystem {
inherit system pkgs;
modules = [
./configuration.nix
./hardware-configuration.nix
./systems/desktop.nix
];

View file

@ -10,7 +10,7 @@
"xsetroot -cursor_name left_ptr"
"xsetroot -solid \"#000000\""
"flashfocus"
"polkit-gnome-authentication-agent-1"
"polkit-gnome"
];
settings = {
border_width = 0;
@ -25,7 +25,7 @@
};
monitors = {
HDMI-0 = [ "I" "II" "III" "IV" "V" ];
# eDP-1 = [ "VI" "VII" "VIII" "IX" "X" ];
eDP-1 = [ "VI" "VII" "VIII" "IX" "X" ];
};
};
}

View file

@ -1,6 +0,0 @@
#!/usr/bin/env bash
u=$(xprop -name "Polybar tray window" _NET_WM_PID | awk '{print $3}')
if [ $u -Z ]
then polybar tray &
else kill $u
fi

View file

@ -1,6 +1,8 @@
{ pkgs, ... }:
{
programs.git = {
enable = true;
package = pkgs.gitFull;
userName = "ISnortPennies";
userEmail = "ISnortPennies@protonmail.com";
};

View file

@ -1,7 +1,6 @@
{config, pkgs, home-manager, ...}:
{
imports = [
./zsh.nix
./firefox.nix
./bspwm.nix
./sxhkd.nix
@ -12,6 +11,7 @@
./theme.nix
./picom.nix
./git.nix
./neovim.nix
];
xsession.numlock.enable = true;
programs.home-manager.enable = true;

34
home-manager/neovim.nix Normal file
View file

@ -0,0 +1,34 @@
{ pkgs, ... }:
{
programs.neovim = {
enable = true;
viAlias = true;
vimAlias = true;
withNodeJs = true;
withPython3 = true;
withRuby = true;
coc = {
enable = true;
package = pkgs.vimPlugins.coc-nvim;
};
plugins = with pkgs.vimPlugins; [
vim-nix
vim-polyglot
vim-smoothie
tokyonight-nvim
rainbow
indentLine
undotree
];
extraConfig = ''
set tabstop=2
set expandtab
set shiftwidth=2
set ignorecase
set incsearch
set number
set noswapfile
let mapleader = "'"
'';
};
}

View file

@ -199,7 +199,7 @@
"module/tray" = {
type = "custom/text";
content = " ";
click.left = "\$HOME/.config/polybar/scripts/tray";
click.left = "polybar-tray";
label = {
padding = 3;
background = "\${colors.background}";

View file

@ -1,7 +1,5 @@
{pkgs, config, lib, modulesPath, ...}:
{
boot = {
kernelPackages = pkgs.linuxPackages_latest;
blacklistedKernelModules = [ "nouveau" "lbm-nouveau" "pcspkr" ];
kernelParams = [ "fbcon=nodefer" "bgrt_disable" "quiet" "splash" ];
plymouth = {

View file

@ -1,53 +0,0 @@
{ config, pkgs, lib, ... }:
{
nix.settings.auto-optimise-store = true;
networking = {
firewall.enable = true;
firewall.allowPing = true;
useDHCP = lib.mkDefault true;
networkmanager.enable = true;
};
qt5 = {
enable = true;
style = "gtk2";
platformTheme = "gtk2";
};
programs = {
zsh.enable = true;
dconf.enable = true;
};
time.timeZone = "America/New_York";
services = {
gvfs.enable = true;
timesyncd = {
enable = true;
servers = [
"time.google.com"
"time2.google.com"
];
};
};
# Select internationalisation properties.
i18n.defaultLocale = "en_US.UTF-8";
console = {
font = "Lat2-Terminus16";
useXkbConfig = true;
};
# Enable sound.
security.rtkit.enable = true;
hardware.pulseaudio = {
enable = true;
support32Bit = true;
package = pkgs.pulseaudioFull;
};
nixpkgs.config.pulseaudio = true;
#enable ssh
programs.mtr.enable = true;
programs.gnupg.agent = {
enable = true;
enableSSHSupport = true;
};
services.openssh.enable = true;
}

View file

@ -1,9 +1,8 @@
{ config, ... }:
{
hardware = {
nvidia = {
nvidiaPersistenced = true;
nvidiaPersistenced = false;
nvidiaSettings = true;
package = config.boot.kernelPackages.nvidiaPackages.stable;
modesetting.enable = true;

View file

@ -1,7 +1,6 @@
{ config, pkgs, callPackage, ... }:
{
environment.systemPackages = with pkgs; [
nano #editor
wget
htop #view tasks
efibootmgr #efi editor
@ -12,7 +11,6 @@ environment.systemPackages = with pkgs; [
lightdm-mini-greeter
#needed utils
mesa #3d acceleration
git #git duh
pciutils
binutils
alsa-utils

View file

@ -4,6 +4,9 @@
{
output = "HDMI-0";
primary = true;
monitorConfig = ''
Option "DPMS" "false"
'';
}
];
screenSection = ''

View file

@ -25,6 +25,15 @@ let
#!${pkgs.stdenv.shell}
nixos-rebuild switch --flake /etc/nixos/#
'';
polybar-tray = pkgs.writeScriptBin "polybar-tray" ''
#!${pkgs.stdenv.shell}
u=$(xprop -name "Polybar tray window" _NET_WM_PID | awk '{print $3}')
if [ $u -Z ]
then polybar tray &
else kill $u
fi
'';
in {
environment.systemPackages = [ update-system clean-store apply-users apply-system ];
environment.systemPackages = [ update-system clean-store apply-users apply-system polybar-tray ];
}

View file

@ -1,5 +1,6 @@
{pkgs, ...}:
{
services.gvfs.enable = true;
programs.thunar = {
enable = true;
plugins = with pkgs.xfce; [ thunar-volman thunar-archive-plugin thunar-media-tags-plugin];

View file

@ -8,6 +8,7 @@
else [ "nvidia" ];
layout = "us";
libinput.enable = true;
xautolock.enable = false;
desktopManager = {
xterm.enable = false;
};

View file

@ -2,13 +2,16 @@
programs = {
zsh = {
enable = true;
enableAutosuggestions = true;
enableSyntaxHighlighting = true;
completionInit = "neofetch";
autosuggestions = {
enable = true;
};
syntaxHighlighting = {
enable = true;
};
interactiveShellInit = "neofetch";
};
starship = {
enable = true;
enableZshIntegration = true;
settings = {
add_newline = false;
format="$sudo \n $directory$git_branch$character";

View file

@ -9,32 +9,25 @@
../modules/fonts.nix
../modules/thunar.nix
../modules/scripts.nix
../modules/misc.nix
../modules/vfio.nix
../modules/refreshrate.nix
../modules/xserver.nix
../modules/smb.nix
../modules/zsh.nix
];
networking.hostName = "gerg-desktop";
nix = {
package = pkgs.nixFlakes;
extraOptions = ''
experimental-features = nix-command flakes
'';
};
system.stateVersion = "22.11";
hardware.cpu.amd.updateMicrocode = true;
# end important stuff
#end important stuff
environment.systemPackages = with pkgs; [
android-tools
openjdk
];
# user managment
#user managment
users = {
defaultUserShell = pkgs.dash;
defaultUserShell = pkgs.zsh;
users.gerg = {
isNormalUser = true;
shell = pkgs.zsh;
extraGroups = [ "wheel" "audio" "networkmanager" "kvm" "libvirtd" ];
};
};

View file

@ -10,29 +10,22 @@
../modules/fonts.nix
../modules/thunar.nix
../modules/scripts.nix
../modules/misc.nix
../modules/xserver.nix
../modules/zsh.nix
];
networking.hostName = "gerg-laptop";
nix = {
package = pkgs.nixFlakes;
extraOptions = ''
experimental-features = nix-command flakes
'';
};
system.stateVersion = "22.11";
hardware.cpu.amd.updateMicrocode = true;
# end important stuff
environment.systemPackages = with pkgs; [
xorg.xf86videoamdgpu
];
# user managment
users = {
defaultUserShell = pkgs.dash;
defaultUserShell = pkgs.zsh;
users.gerg = {
isNormalUser = true;
shell = pkgs.zsh;
extraGroups = [ "wheel" "audio" "networkmanager"];
};
};