Compare commits

23 Commits
main ... server

Author SHA1 Message Date
b30b3969f2 removed user 2025-01-19 17:24:15 -08:00
3f0ffe65d9 removed user 2025-01-19 17:20:41 -08:00
dcaa8e12d1 added init for zsh 2025-01-18 02:57:27 -08:00
20dc313f96 nerdfonts 2025-01-18 02:47:48 -08:00
aea284a05d Fixed install.sh 2025-01-18 02:42:21 -08:00
22db4be6fa Added user creation 2025-01-18 02:23:20 -08:00
df9a7f6670 Fixed install.sh and others 2025-01-18 02:14:27 -08:00
5fdf334224 Fixed install.sh 2025-01-17 22:57:56 -08:00
048071ae76 Fixed install.sh 2025-01-17 01:36:31 -08:00
fe3a31818c Fixed cli-tools 2025-01-17 01:34:13 -08:00
bf49baeb28 Major fixes, removed flakes 2025-01-17 01:30:36 -08:00
c26161a21f fixed flake format 2025-01-17 00:40:41 -08:00
53ceea37d7 fixed flake format 2025-01-17 00:15:43 -08:00
b5810551c0 fixed flake format 2025-01-17 00:12:03 -08:00
34178ce1e8 fixed flake format 2025-01-17 00:06:07 -08:00
0a6566f394 fixed flake format 2025-01-17 00:05:15 -08:00
2a172ee6de fixed flake format 2025-01-16 23:56:13 -08:00
d6cee1e554 fixed flake format 2025-01-16 23:54:38 -08:00
aeda1c3e59 update flakes 2025-01-16 23:49:40 -08:00
f57d25b2bf homemanger update 2025-01-16 23:08:00 -08:00
b166a89091 install script 2025-01-16 22:35:09 -08:00
2312d47bba updated flake.nix 2025-01-14 01:28:54 -08:00
e923b34960 intial 2025-01-11 00:52:48 -08:00
8 changed files with 58 additions and 1132 deletions

View File

@@ -1,218 +0,0 @@
# Edit this configuration file to define what should be installed on
# your system. Help is available in the configuration.nix(5) man page
# and in the NixOS manual (accessible by running nixos-help).
{ config, pkgs, inputs, ... }:
{
imports =
[ # Include the results of the hardware scan.
./hardware-configuration.nix
inputs.home-manager.nixosModules.default
];
# Bootloader.
boot.loader.systemd-boot.enable = true;
boot.loader.efi.canTouchEfiVariables = true;
nix.settings.experimental-features = ["nix-command" "flakes"];
networking.hostName = "EVA-01"; # Define your hostname.
# networking.wireless.enable = true; # Enables wireless support via wpa_supplicant.
# Configure network proxy if necessary
# networking.proxy.default = "http://user:password@proxy:port/";
# networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain";
# Enable networking
networking.networkmanager.enable = true;
virtualisation.docker.enable = true;
# Set your time zone.
time.timeZone = "America/Los_Angeles";
# Select internationalisation properties.
i18n.defaultLocale = "en_US.UTF-8";
i18n.extraLocaleSettings = {
LC_ADDRESS = "en_US.UTF-8";
LC_IDENTIFICATION = "en_US.UTF-8";
LC_MEASUREMENT = "en_US.UTF-8";
LC_MONETARY = "en_US.UTF-8";
LC_NAME = "en_US.UTF-8";
LC_NUMERIC = "en_US.UTF-8";
LC_PAPER = "en_US.UTF-8";
LC_TELEPHONE = "en_US.UTF-8";
LC_TIME = "en_US.UTF-8";
};
# Enable the X11 windowing system.
# You can disable this if you're only using the Wayland session.
services.xserver.enable = false;
# Enable the KDE Plasma Desktop Environment.
services.displayManager.sddm.enable = true;
services.displayManager.sddm.wayland.enable = true;
services.desktopManager.plasma6.enable = true;
services.tailscale.enable = true;
services.fprintd.enable = true;
services.fprintd.tod.enable = true;
services.fprintd.tod.driver = pkgs.libfprint-2-tod1-goodix;
# Configure keymap in X11
services.xserver.xkb = {
layout = "us";
variant = "";
};
# Enable CUPS to print documents.
services.printing.enable = false;
# Enable sound with pipewire.
hardware.pulseaudio.enable = false;
#hardware.pulseaudio = {
# enable = true;
# package = pkgs.pulseaudioFull;
#};
hardware.bluetooth.enable = true;
security.rtkit.enable = true;
services.pipewire = {
enable = true;
alsa.enable = true;
alsa.support32Bit = true;
pulse.enable = true;
# If you want to use JACK applications, uncomment this
#jack.enable = true;
# use the example session manager (no others are packaged yet so this is enabled by default,
# no need to redefine it in your config for now)
#media-session.enable = true;
};
# Enable touchpad support (enabled default in most desktopManager).
# services.xserver.libinput.enable = true;
# Define a user account. Don't forget to set a password with passwd.
programs.zsh.enable = true;
users.users.rogueking = {
isNormalUser = true;
description = "rogueking";
extraGroups = [ "networkmanager" "wheel" "docker" ];
shell = pkgs.zsh;
#packages = [ inputs.home-manager.packages.${pkgs.system}.default ];
packages = with pkgs; [
bat
brave
btop
kdePackages.kate
localsend
neovim
tldr
vesktop
# thunderbird
];
};
# Install firefox.
programs.firefox.enable = true;
# Allow unfree packages
nixpkgs.config.allowUnfree = true;
security.polkit.enable = true;
programs._1password.enable = true;
programs._1password-gui = {
enable = true;
# Certain features, including CLI integration and system authentication support,
# require enabling PolKit integration on some desktop environments (e.g. Plasma).
polkitPolicyOwners = [ "rogueking" ];
};
# Enable OpenSSH daemon
services.openssh.enable = true;
# List packages installed in system profile. To search, run:
# $ nix search wget
environment.systemPackages = with pkgs; [
#apps
fprintd
jellyfin-media-player
kdePackages.bluedevil
kdePackages.bluez-qt
kdePackages.kdeconnect-kde
kdePackages.oxygen-sounds
kdePackages.partitionmanager
moonlight-qt
obsidian
prismlauncher
qFlipper
remmina
vesktop
wireshark
#cli tools
android-tools
metasploit
nettools
nmap
oh-my-zsh
openssh
thefuck
tlp
unzip
vim
wget
];
fonts.packages = with pkgs; [
nerdfonts
];
home-manager = {
extraSpecialArgs = { inherit inputs; };
users = {
"rogueking" = import ./home-manager/home.nix;
};
backupFileExtension = "backup";
};
#home-manager = {
# extraSpecialArgs = { inherit inputs; };
# users = {
# "rogueking" = import ../home-manager/home.nix;
# };
# backupFileExtension = "backup";
#};
# Some programs need SUID wrappers, can be configured further or are
# started in user sessions.
# programs.mtr.enable = true;
# programs.gnupg.agent = {
# enable = true;
# enableSSHSupport = true;
# };
# List services that you want to enable:
# Enable the OpenSSH daemon.
# services.openssh.enable = true;
# Open ports in the firewall.
# networking.firewall.allowedTCPPorts = [ ... ];
# networking.firewall.allowedUDPPorts = [ ... ];
# Or disable the firewall altogether.
# networking.firewall.enable = false;
# This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions
# on your system were taken. Its perfectly fine and recommended to leave
# this value at the release version of the first install of this system.
# Before changing this value read the documentation for this option
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
system.stateVersion = "24.11"; # Did you read the comment?
}

459
flake.lock generated
View File

@@ -1,459 +0,0 @@
{
"nodes": {
"devshell": {
"inputs": {
"nixpkgs": [
"nixvim",
"nixpkgs"
]
},
"locked": {
"lastModified": 1735644329,
"narHash": "sha256-tO3HrHriyLvipc4xr+Ewtdlo7wM1OjXNjlWRgmM7peY=",
"owner": "numtide",
"repo": "devshell",
"rev": "f7795ede5b02664b57035b3b757876703e2c3eac",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "devshell",
"type": "github"
}
},
"flake-compat": {
"flake": false,
"locked": {
"lastModified": 1696426674,
"narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=",
"owner": "edolstra",
"repo": "flake-compat",
"rev": "0f9255e01c2351cc7d116c072cb317785dd33b33",
"type": "github"
},
"original": {
"owner": "edolstra",
"repo": "flake-compat",
"type": "github"
}
},
"flake-compat_2": {
"locked": {
"lastModified": 1696426674,
"narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=",
"rev": "0f9255e01c2351cc7d116c072cb317785dd33b33",
"revCount": 57,
"type": "tarball",
"url": "https://api.flakehub.com/f/pinned/edolstra/flake-compat/1.0.1/018afb31-abd1-7bff-a5e4-cff7e18efb7a/source.tar.gz"
},
"original": {
"type": "tarball",
"url": "https://flakehub.com/f/edolstra/flake-compat/1.tar.gz"
}
},
"flake-parts": {
"inputs": {
"nixpkgs-lib": [
"nixvim",
"nixpkgs"
]
},
"locked": {
"lastModified": 1735774679,
"narHash": "sha256-soePLBazJk0qQdDVhdbM98vYdssfs3WFedcq+raipRI=",
"owner": "hercules-ci",
"repo": "flake-parts",
"rev": "f2f7418ce0ab4a5309a4596161d154cfc877af66",
"type": "github"
},
"original": {
"owner": "hercules-ci",
"repo": "flake-parts",
"type": "github"
}
},
"flake-utils": {
"inputs": {
"systems": "systems"
},
"locked": {
"lastModified": 1705309234,
"narHash": "sha256-uNRRNRKmJyCRC/8y1RqBkqWBLM034y4qN7EprSdmgyA=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "1ef2e671c3b0c19053962c07dbda38332dcebf26",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"flake-utils_2": {
"inputs": {
"systems": "systems_2"
},
"locked": {
"lastModified": 1731533236,
"narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "11707dc2f618dd54ca8739b309ec4fc024de578b",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"ghostty": {
"inputs": {
"flake-compat": "flake-compat",
"nixpkgs-stable": "nixpkgs-stable",
"nixpkgs-unstable": "nixpkgs-unstable",
"zig": "zig"
},
"locked": {
"lastModified": 1736005074,
"narHash": "sha256-6W7Cg4Lf0/gT4r/Bloj9lwxKw+Txti3Bw1ybrEpn0CA=",
"owner": "ghostty-org",
"repo": "ghostty",
"rev": "8f5f432ab61fa73b77cb61239c0cff34250f77bb",
"type": "github"
},
"original": {
"owner": "ghostty-org",
"repo": "ghostty",
"type": "github"
}
},
"git-hooks": {
"inputs": {
"flake-compat": [
"nixvim",
"flake-compat"
],
"gitignore": "gitignore",
"nixpkgs": [
"nixvim",
"nixpkgs"
]
},
"locked": {
"lastModified": 1735882644,
"narHash": "sha256-3FZAG+pGt3OElQjesCAWeMkQ7C/nB1oTHLRQ8ceP110=",
"owner": "cachix",
"repo": "git-hooks.nix",
"rev": "a5a961387e75ae44cc20f0a57ae463da5e959656",
"type": "github"
},
"original": {
"owner": "cachix",
"repo": "git-hooks.nix",
"type": "github"
}
},
"gitignore": {
"inputs": {
"nixpkgs": [
"nixvim",
"git-hooks",
"nixpkgs"
]
},
"locked": {
"lastModified": 1709087332,
"narHash": "sha256-HG2cCnktfHsKV0s4XW83gU3F57gaTljL9KNSuG6bnQs=",
"owner": "hercules-ci",
"repo": "gitignore.nix",
"rev": "637db329424fd7e46cf4185293b9cc8c88c95394",
"type": "github"
},
"original": {
"owner": "hercules-ci",
"repo": "gitignore.nix",
"type": "github"
}
},
"home-manager": {
"inputs": {
"nixpkgs": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1735344290,
"narHash": "sha256-oJDtWPH1oJT34RJK1FSWjwX4qcGOBRkcNQPD0EbSfNM=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "613691f285dad87694c2ba1c9e6298d04736292d",
"type": "github"
},
"original": {
"owner": "nix-community",
"ref": "release-24.11",
"repo": "home-manager",
"type": "github"
}
},
"home-manager_2": {
"inputs": {
"nixpkgs": [
"nixvim",
"nixpkgs"
]
},
"locked": {
"lastModified": 1735344290,
"narHash": "sha256-oJDtWPH1oJT34RJK1FSWjwX4qcGOBRkcNQPD0EbSfNM=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "613691f285dad87694c2ba1c9e6298d04736292d",
"type": "github"
},
"original": {
"owner": "nix-community",
"ref": "release-24.11",
"repo": "home-manager",
"type": "github"
}
},
"ixx": {
"inputs": {
"flake-utils": [
"nixvim",
"nuschtosSearch",
"flake-utils"
],
"nixpkgs": [
"nixvim",
"nuschtosSearch",
"nixpkgs"
]
},
"locked": {
"lastModified": 1729958008,
"narHash": "sha256-EiOq8jF4Z/zQe0QYVc3+qSKxRK//CFHMB84aYrYGwEs=",
"owner": "NuschtOS",
"repo": "ixx",
"rev": "9fd01aad037f345350eab2cd45e1946cc66da4eb",
"type": "github"
},
"original": {
"owner": "NuschtOS",
"ref": "v0.0.6",
"repo": "ixx",
"type": "github"
}
},
"nix-darwin": {
"inputs": {
"nixpkgs": [
"nixvim",
"nixpkgs"
]
},
"locked": {
"lastModified": 1735956190,
"narHash": "sha256-svzx3yVXD5tbBJZCn3Lt1RriH8GHo6CyVUPTHejf7sU=",
"owner": "lnl7",
"repo": "nix-darwin",
"rev": "3feaf376d75d3d58ebf7e9a4f584d00628548ad9",
"type": "github"
},
"original": {
"owner": "lnl7",
"repo": "nix-darwin",
"type": "github"
}
},
"nixpkgs": {
"locked": {
"lastModified": 1735922141,
"narHash": "sha256-vk0xwGZSlvZ/596yxOtsk4gxsIx2VemzdjiU8zhjgWw=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "d29ab98cd4a70a387b8ceea3e930b3340d41ac5a",
"type": "github"
},
"original": {
"owner": "nixos",
"ref": "nixos-24.11",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs-stable": {
"locked": {
"lastModified": 1733423277,
"narHash": "sha256-TxabjxEgkNbCGFRHgM/b9yZWlBj60gUOUnRT/wbVQR8=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "e36963a147267afc055f7cf65225958633e536bf",
"type": "github"
},
"original": {
"owner": "nixos",
"ref": "release-24.11",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs-unstable": {
"locked": {
"lastModified": 1733229606,
"narHash": "sha256-FLYY5M0rpa5C2QAE3CKLYAM6TwbKicdRK6qNrSHlNrE=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "566e53c2ad750c84f6d31f9ccb9d00f823165550",
"type": "github"
},
"original": {
"owner": "nixos",
"ref": "nixpkgs-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"nixvim": {
"inputs": {
"devshell": "devshell",
"flake-compat": "flake-compat_2",
"flake-parts": "flake-parts",
"git-hooks": "git-hooks",
"home-manager": "home-manager_2",
"nix-darwin": "nix-darwin",
"nixpkgs": [
"nixpkgs"
],
"nuschtosSearch": "nuschtosSearch",
"treefmt-nix": "treefmt-nix"
},
"locked": {
"lastModified": 1735993984,
"narHash": "sha256-Syew+5yuzysUr07SrGD+GRfZjE11h36TSYbxzEHYyyc=",
"owner": "nix-community",
"repo": "nixvim",
"rev": "6bd1c7c5927fa9fdfdfd68f5aa772e6a62b9d779",
"type": "github"
},
"original": {
"owner": "nix-community",
"ref": "nixos-24.11",
"repo": "nixvim",
"type": "github"
}
},
"nuschtosSearch": {
"inputs": {
"flake-utils": "flake-utils_2",
"ixx": "ixx",
"nixpkgs": [
"nixvim",
"nixpkgs"
]
},
"locked": {
"lastModified": 1735854821,
"narHash": "sha256-Iv59gMDZajNfezTO0Fw6LHE7uKAShxbvMidmZREit7c=",
"owner": "NuschtOS",
"repo": "search",
"rev": "836908e3bddd837ae0f13e215dd48767aee355f0",
"type": "github"
},
"original": {
"owner": "NuschtOS",
"repo": "search",
"type": "github"
}
},
"root": {
"inputs": {
"ghostty": "ghostty",
"home-manager": "home-manager",
"nixpkgs": "nixpkgs",
"nixvim": "nixvim"
}
},
"systems": {
"locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default",
"type": "github"
}
},
"systems_2": {
"locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default",
"type": "github"
}
},
"treefmt-nix": {
"inputs": {
"nixpkgs": [
"nixvim",
"nixpkgs"
]
},
"locked": {
"lastModified": 1735905407,
"narHash": "sha256-1hKMRIT+QZNWX46e4gIovoQ7H8QRb7803ZH4qSKI45o=",
"owner": "numtide",
"repo": "treefmt-nix",
"rev": "29806abab803e498df96d82dd6f34b32eb8dd2c8",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "treefmt-nix",
"type": "github"
}
},
"zig": {
"inputs": {
"flake-compat": [
"ghostty"
],
"flake-utils": "flake-utils",
"nixpkgs": [
"ghostty",
"nixpkgs-stable"
]
},
"locked": {
"lastModified": 1717848532,
"narHash": "sha256-d+xIUvSTreHl8pAmU1fnmkfDTGQYCn2Rb/zOwByxS2M=",
"owner": "mitchellh",
"repo": "zig-overlay",
"rev": "02fc5cc555fc14fda40c42d7c3250efa43812b43",
"type": "github"
},
"original": {
"owner": "mitchellh",
"repo": "zig-overlay",
"type": "github"
}
}
},
"root": "root",
"version": 7
}

View File

@@ -1,39 +0,0 @@
{
description = "Nixos Config Flake";
inputs = {
nixpkgs.url = "github:nixos/nixpkgs/nixos-24.11";
home-manager = {
url = "github:nix-community/home-manager/release-24.11";
inputs.nixpkgs.follows = "nixpkgs";
};
nixvim = {
url = "github:nix-community/nixvim/nixos-24.11";
inputs.nixpkgs.follows = "nixpkgs";
};
ghostty = {
url = "github:ghostty-org/ghostty";
};
};
outputs = { self, nixpkgs, home-manager, nixvim, ghostty, ... }@inputs: {
nixosConfigurations = {
default = nixpkgs.lib.nixosSystem {
specialArgs = {inherit inputs;};
system = "x86_64-linux";
modules = [
./configuration.nix
inputs.home-manager.nixosModules.default
{
environment.systemPackages = [
ghostty.packages.x86_64-linux.default
];
}
];
};
};
};
}

View File

@@ -1,38 +0,0 @@
# Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead.
{ config, lib, pkgs, modulesPath, ... }:
{
imports =
[ (modulesPath + "/installer/scan/not-detected.nix")
];
boot.initrd.availableKernelModules = [ "xhci_pci" "thunderbolt" "nvme" "uas" "sd_mod" ];
boot.initrd.kernelModules = [ ];
boot.kernelModules = [ "kvm-intel" ];
boot.extraModulePackages = [ ];
fileSystems."/" =
{ device = "/dev/disk/by-uuid/0ec1b4fd-ca0f-4938-a038-37a69ec00b21";
fsType = "ext4";
};
fileSystems."/boot" =
{ device = "/dev/disk/by-uuid/2066-E44D";
fsType = "vfat";
options = [ "fmask=0077" "dmask=0077" ];
};
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
# still possible to use this option, but it's recommended to use it in conjunction
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
networking.useDHCP = lib.mkDefault true;
# networking.interfaces.wlp0s20f3.useDHCP = lib.mkDefault true;
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
}

View File

@@ -2,12 +2,25 @@
{
home.packages = with pkgs; [
#cli tools
bat
btop
curl
dust
tldr
tailscale
docker
dust
ghostty
git
neovim
nettools
nix-prefetch-github
nmap
openssh
tailscale
thefuck
tldr
unzip
vim
wget
];
programs = {
@@ -24,8 +37,7 @@
git = {
enable = true;
userName = "rogueking";
userEmail = "miguel@muniz.org";
userName = "USER";
};
eza = {
@@ -72,14 +84,17 @@
grep = "grep --color=auto";
ll = "eza -la";
lg = "lazygit";
fk = "fuck";
fu = "fuck";
lt = "eza --tree";
cd = "z";
cat = "bat";
catp = "bat -p";
btop = "btop --utf-force";
open = "xdg-open";
rebuild = "sudo nixos-rebuild switch --flake /etc/nixos#default";
};
initExtra = ''
. ~/.nix-profile/etc/profile.d/nix.sh
fastfetch
'';

View File

@@ -5,14 +5,12 @@
./cli-tools.nix
./fastfetch/fastfetch.nix
./direnv.nix
./nixvim/nixvim.nix
inputs.nixvim.homeManagerModules.nixvim
];
# Home Manager needs a bit of information about you and the paths it should
# manage.
home.username = "rogueking";
home.homeDirectory = "/home/rogueking";
home.username = "USER";
home.homeDirectory = "/home/USER";
# This value determines the Home Manager release that your configuration is
# compatible with. This helps avoid breakage when a new Home Manager release
@@ -25,11 +23,12 @@
nixpkgs.config.allowUnfree = true;
fonts.fontconfig.enable = true;
# The home.packages option allows you to install Nix packages into your
# environment.
home.packages = with pkgs; [
#(pkgs.nerdfonts.override { fonts = [ "FiraCode" "DroidSansMono" ]; })
];
# Home Manager is pretty good at managing dotfiles. The primary way to manage

View File

@@ -1,365 +0,0 @@
{
programs = {
nixvim = {
enable = true;
defaultEditor = true;
viAlias = true;
vimAlias = true;
#colorschemes.onedark.enable = true;
#colorschemes.everforest = {
# enable = true;
# settings = {
# background = "hard";
# transparent_background = 1;
# };
#};
opts = {
number = true;
relativenumber = true;
expandtab = true;
shiftwidth = 2;
tabstop = 2;
};
diagnostics = {
virtual_text = true;
update_in_insert = true;
severity_sort = true;
};
globals = {
mapleader = " ";
maplocalleader = " ";
};
keymaps = [
{
action = ":q<CR>";
key = "<leader>q";
options = {
silent = true;
noremap = true;
desc = "Quit";
};
}
{
action = ":w<CR>";
key = "<leader>w";
options = {
silent = true;
noremap = true;
desc = "Save";
};
}
{
action = ":wq<CR>";
key = "<leader>wq";
options = {
silent = true;
noremap = true;
desc = "Save and quit";
};
}
{
action = "<C-\\><C-n>:ToggleTerm direction=float<CR>";
key = "<leader>t";
mode = [ "n" "v" "t" ];
options = {
silent = true;
noremap = true;
desc = "Toggle floating terminal";
};
}
{
action = ":Telescope live_grep<CR>";
key = "<leader>lg";
options = {
silent = true;
noremap = true;
desc = "Live grep";
};
}
{
action = ":Telescope find_files<CR>";
key = "<leader>ff";
options = {
silent = true;
noremap = true;
desc = "Find file";
};
}
{
action = ":Telescope oldfiles<CR>";
key = "<leader>of";
options = {
silent = true;
noremap = true;
desc = "Browse recent files";
};
}
{
action = ":Telescope file_browser<CR>";
key = "<leader>fb";
options = {
silent = true;
noremap = true;
desc = "Directory-based file browser";
};
}
{
action = ":Neotree toggle reveal<CR>";
key = "<leader>nt";
options = {
silent = true;
noremap = true;
desc = "Toggle file tree";
};
}
];
plugins = {
comment.enable = true;
direnv.enable = true;
gitsigns.enable = true;
intellitab.enable = true;
lastplace.enable = true;
lsp-format.enable = true;
lspsaga.enable = true;
lualine.enable = true;
luasnip.enable = true;
multicursors.enable = true;
neo-tree.enable = true;
neoscroll.enable = true;
nix.enable = true;
nvim-autopairs.enable = true;
nvim-colorizer.enable = true;
refactoring.enable = true;
toggleterm.enable = true;
treesitter.enable = true;
web-devicons.enable = true;
telescope = {
enable = true;
extensions.file-browser.enable = true;
};
transparent = {
enable = true;
settings = {
groups = [
"Normal"
"NormalNC"
"Comment"
"Constant"
"Special"
"Identifier"
"Statement"
"PreProc"
"Type"
"Underlined"
"Todo"
"String"
"Function"
"Conditional"
"Repeat"
"Operator"
"Structure"
"LineNr"
"NonText"
"SignColumn"
"CursorLine"
"CursorLineNr"
"StatusLine"
"StatusLineNC"
"EndOfBuffer"
];
};
};
lint = {
enable = true;
autoCmd = {
event = [ "InsertLeave" "TextChanged" ];
};
};
illuminate = {
enable = true;
delay = 100;
minCountToHighlight = 1;
modesAllowlist = ["n" "i" "v"];
};
ollama = {
enable = true;
#url = ;
};
which-key = {
enable = true;
settings = {
preset = "modern";
delay = 500;
expand = 1;
notify = false;
win = {
border = "single";
padding = [1 1];
wo.winblend = 10;
};
replace = {
desc = [
[
"<space>"
"SPACE"
]
[
"<leader>"
"SPACE"
]
[
"<[cC][rR]>"
"RETURN"
]
[
"<[tT][aA][bB]>"
"TAB"
]
[
"<[bB][sS]>"
"BACKSPACE"
]
];
};
};
};
scrollview = {
enable = true;
settings = {
signs_on_startup = [
"all"
];
};
};
startup = {
enable = true;
parts = [ "header" "body" ];
sections = {
header = {
align = "center";
content = {
__raw = "require('startup.headers').hydra_header";
};
defaultColor = "";
foldSection = false;
highlight = "Statement";
margin = 5;
oldfilesAmount = 0;
title = "Header";
type = "text";
};
body = {
align = "center";
content = [
[
" Find File"
"Telescope find_files"
"<leader>ff"
]
[
"󰍉 Find Word"
"Telescope live_grep"
"<leader>lg"
]
[
" Recent Files"
"Telescope oldfiles"
"<leader>of"
]
[
" File Browser"
"Telescope file_browser"
"<leader>fb"
]
[
" New File"
"lua require'startup'.new_file()"
"<leader>nf"
]
];
defaultColor = "";
foldSection = false;
highlight = "String";
margin = 5;
oldfilesAmount = 0;
title = "Basic Commands";
type = "mapping";
};
};
};
indent-blankline = {
enable = true;
settings = {
scope = {
show_end = true;
show_exact_scope = true;
show_start = true;
};
};
};
cmp = {
enable = true;
autoEnableSources = true;
settings = {
sources = [
{name = "nvim_lsp";}
{name = "path";}
{name = "buffer";}
{name = "luasnip";}
];
mapping = {
"<C-Space>" = "cmp.mapping.complete()";
"<C-d>" = "cmp.mapping.scroll_docs(-4)";
"<C-e>" = "cmp.mapping.close()";
"<C-f>" = "cmp.mapping.scroll_docs(4)";
"<CR>" = "cmp.mapping.confirm({ select = true })";
"<S-Tab>" = "cmp.mapping(cmp.mapping.select_prev_item(), {'i', 's'})";
"<Tab>" = "cmp.mapping(cmp.mapping.select_next_item(), {'i', 's'})";
};
};
};
lsp = {
enable = true;
servers = {
nixd = {
enable = true;
extraOptions = {
offset_encoding = "utf-8";
};
};
ts_ls.enable = true;
gopls.enable = true;
golangci_lint_ls.enable = true;
rust_analyzer = {
enable = true;
installCargo = true;
installRustc = true;
};
};
};
};
};
};
}

31
install.sh Normal file
View File

@@ -0,0 +1,31 @@
!#/bin/bash
echo "Intalling nix and home-manager"
sh <(curl -L https://nixos.org/nix/install) --no-daemon
mkdir -p ~/.config/nix
echo "experimental-features = nix-command flakes" >>~/.config/nix/nix.conf
. ~/.nix-profile/etc/profile.d/nix.sh
nix-channel --add https://nixos.org/channels/nixos-24.11 nixpkgs
nix-channel --add https://github.com/nix-community/home-manager/archive/release-24.11.tar.gz home-manager
nix-channel --update
nix-shell '<home-manager>' -A install
cp -r home-manager/ ~/.config/
home-manager switch
sudo echo "/home/$USER/.nix-profile/bin/zsh" | sudo tee -a /etc/shells
. ~/.nix-profile/etc/profile.d/nix.sh
chsh -s /home/$USER/.nix-profile/bin/zsh $USER
source ~/.zshrc
#sudo echo ". ~/.nix-profile/etc/profile.d/nix.sh" | sudo tee -a ~/.bashrc
#sudo echo "zsh" | sudo tee -a ~/.bashrc