Back to NixOS!
This commit is contained in:
parent
6cae65deb0
commit
65b85b2323
67
.Xdefaults
67
.Xdefaults
|
@ -1,67 +0,0 @@
|
|||
|
||||
! Gruvbox theme
|
||||
! hard contrast: *background: #1d2021
|
||||
*background: #282828
|
||||
! soft contrast: *background: #32302f
|
||||
*foreground: #ebdbb2
|
||||
! Black + DarkGrey
|
||||
*color0: #282828
|
||||
*color8: #928374
|
||||
! DarkRed + Red
|
||||
*color1: #cc241d
|
||||
*color9: #fb4934
|
||||
! DarkGreen + Green
|
||||
*color2: #98971a
|
||||
*color10: #b8bb26
|
||||
! DarkYellow + Yellow
|
||||
*color3: #d79921
|
||||
*color11: #fabd2f
|
||||
! DarkBlue + Blue
|
||||
*color4: #458588
|
||||
*color12: #83a598
|
||||
! DarkMagenta + Magenta
|
||||
*color5: #b16286
|
||||
*color13: #d3869b
|
||||
! DarkCyan + Cyan
|
||||
*color6: #689d6a
|
||||
*color14: #8ec07c
|
||||
! LightGrey + White
|
||||
*color7: #a89984
|
||||
*color15: #ebdbb2
|
||||
|
||||
Xft.dpi: 96
|
||||
Xft.antialias: true
|
||||
Xft.rgba: rgb
|
||||
Xft.hinting: true
|
||||
Xft.hintstyle: hintfull
|
||||
|
||||
! URxvt settings
|
||||
|
||||
URxvt.scrollBar: false
|
||||
|
||||
URxvt*depth: 32
|
||||
URxvt*fading: 15
|
||||
URxvt*background: rgba:2800/2800/2800/cc00
|
||||
URxvt*loginShell: true
|
||||
URxvt*saveLines: 20000
|
||||
URxvt*internalBorder: 3
|
||||
URxvt*lineSpace: 0
|
||||
URxvt*keysym.Shift-Control-V: eval:paste_clipboard
|
||||
URxvt*keysym.Shift-Control-C: eval:selection_to_clipboard
|
||||
URxvt*iso14755: false
|
||||
URxvt*iso14755_52: false
|
||||
|
||||
|
||||
URxvt*font: xft:DejaVu Sans Mono:pixelsize=12:antialias=true:hinting=true for Powerline:size=12
|
||||
URxvt*boldFont: xft:DejaVu Sans Mono:bold:pixelsize=12:antialias=true:hinting=true
|
||||
|
||||
|
||||
!-*- Perl extensions -*-
|
||||
URxvt*perl-ext-common: default,selection-to-clipboard,pasta,matcher,keyboard-select,font-size,resize-font
|
||||
URxvt*keysym.C-k: resize-font:increase
|
||||
URxvt*keysym.C-S-k: resize-font:incglobal
|
||||
URxvt*keysym.C-j: resize-font:decrease
|
||||
URxvt*keysym.C-S-j: resize-font:decglobal
|
||||
URxvt*url-launcher: /usr/bin/xdg-open
|
||||
URxvt*matcher.button: 1
|
||||
|
261
config/i3/config
261
config/i3/config
|
@ -1,261 +0,0 @@
|
|||
# This file has been auto-generated by i3-config-wizard(1).
|
||||
|
||||
#
|
||||
# Should you change your keyboard layout some time, delete
|
||||
# this file and re-run i3-config-wizard(1).
|
||||
#
|
||||
|
||||
# i3 config file (v4)
|
||||
#
|
||||
# Please see http://i3wm.org/docs/userguide.html for a complete reference!
|
||||
|
||||
# Mod for Win keyboard
|
||||
set $mod Mod1
|
||||
set $mod1 Mod4
|
||||
# Mod for Mac keyboard
|
||||
#set $mod Mod4
|
||||
#set $mod1 Mod1
|
||||
|
||||
# Font for window titles. Will also be used by the bar unless a different font
|
||||
# is used in the bar {} block below.
|
||||
font pango:DejaVu Sans Mono 8
|
||||
|
||||
# This font is widely installed, provides lots of unicode glyphs, right-to-left
|
||||
# text rendering and scalability on retina/hidpi displays (thanks to pango).
|
||||
#font pango:DejaVu Sans Mono 8
|
||||
|
||||
# Before i3 v4.8, we used to recommend this one as the default:
|
||||
# font -misc-fixed-medium-r-normal--13-120-75-75-C-70-iso10646-1
|
||||
# The font above is very space-efficient, that is, it looks good, sharp and
|
||||
# clear in small sizes. However, its unicode glyph coverage is limited, the old
|
||||
# X core fonts rendering does not support right-to-left and this being a bitmap
|
||||
# font, it doesn’t scale on retina/hidpi displays.
|
||||
|
||||
# Use Mouse+$mod to drag floating windows to their wanted position
|
||||
floating_modifier $mod
|
||||
|
||||
# start a terminal
|
||||
bindsym $mod+Return exec i3-sensible-terminal
|
||||
|
||||
# kill focused window
|
||||
bindsym $mod+q kill
|
||||
|
||||
# start dmenu (a program launcher)
|
||||
bindsym $mod+d exec dmenu_run -nb '#1d2021' -nf '#8a8a8a' -sb '#1d2021' -sf '#396886' -fn 'DejaVu Sans Mono-8'
|
||||
# There also is the (new) i3-dmenu-desktop which only displays applications
|
||||
# shipping a .desktop file. It is a wrapper around dmenu, so you need that
|
||||
# installed.
|
||||
# bindsym $mod+d exec --no-startup-id i3-dmenu-desktop
|
||||
|
||||
# change focus
|
||||
bindsym $mod+h focus left
|
||||
bindsym $mod+j focus down
|
||||
bindsym $mod+k focus up
|
||||
bindsym $mod+l focus right
|
||||
|
||||
# alternatively, you can use the cursor keys:
|
||||
bindsym $mod+Left focus left
|
||||
bindsym $mod+Down focus down
|
||||
bindsym $mod+Up focus up
|
||||
bindsym $mod+Right focus right
|
||||
|
||||
# move focused window
|
||||
bindsym $mod+Shift+h move left
|
||||
bindsym $mod+Shift+j move down
|
||||
bindsym $mod+Shift+k move up
|
||||
bindsym $mod+Shift+l move right
|
||||
|
||||
# alternatively, you can use the cursor keys:
|
||||
bindsym $mod+Shift+Left move left
|
||||
bindsym $mod+Shift+Down move down
|
||||
bindsym $mod+Shift+Up move up
|
||||
bindsym $mod+Shift+Right move right
|
||||
|
||||
# split in horizontal orientation
|
||||
bindsym $mod+o split h
|
||||
|
||||
# split in vertical orientation
|
||||
bindsym $mod+i split v
|
||||
|
||||
# enter fullscreen mode for the focused container
|
||||
bindsym $mod+f fullscreen toggle
|
||||
|
||||
# change container layout (stacked, tabbed, toggle split)
|
||||
bindsym $mod+s layout stacking
|
||||
bindsym $mod+w layout tabbed
|
||||
bindsym $mod+e layout toggle split
|
||||
|
||||
# toggle tiling / floating
|
||||
bindsym $mod+Shift+space floating toggle
|
||||
|
||||
# change focus between tiling / floating windows
|
||||
bindsym $mod+space focus mode_toggle
|
||||
|
||||
# focus the parent container
|
||||
bindsym $mod+p focus parent
|
||||
|
||||
# focus the child container
|
||||
bindsym $mod+n focus child
|
||||
|
||||
# switch to workspace
|
||||
#
|
||||
set $workspace1 "1"
|
||||
set $workspace2 "2"
|
||||
set $workspace3 "3"
|
||||
set $workspace4 "4"
|
||||
set $workspace5 "5"
|
||||
set $workspace6 "6"
|
||||
set $workspace7 "7"
|
||||
set $workspace8 "8"
|
||||
set $workspace9 "9"
|
||||
set $workspace0 "0"
|
||||
|
||||
bindsym $mod+1 workspace $workspace1
|
||||
bindsym $mod+2 workspace $workspace2
|
||||
bindsym $mod+3 workspace $workspace3
|
||||
bindsym $mod+4 workspace $workspace4
|
||||
bindsym $mod+5 workspace $workspace5
|
||||
bindsym $mod+6 workspace $workspace6
|
||||
bindsym $mod+7 workspace $workspace7
|
||||
bindsym $mod+8 workspace $workspace8
|
||||
bindsym $mod+9 workspace $workspace9
|
||||
bindsym $mod+0 workspace $workspace0
|
||||
|
||||
# move focused container to workspace
|
||||
bindsym $mod+Shift+1 move container to workspace $workspace1
|
||||
bindsym $mod+Shift+2 move container to workspace $workspace2
|
||||
bindsym $mod+Shift+3 move container to workspace $workspace3
|
||||
bindsym $mod+Shift+4 move container to workspace $workspace4
|
||||
bindsym $mod+Shift+5 move container to workspace $workspace5
|
||||
bindsym $mod+Shift+6 move container to workspace $workspace6
|
||||
bindsym $mod+Shift+7 move container to workspace $workspace7
|
||||
bindsym $mod+Shift+8 move container to workspace $workspace8
|
||||
bindsym $mod+Shift+9 move container to workspace $workspace9
|
||||
bindsym $mod+Shift+0 move container to workspace $workspace0
|
||||
|
||||
# reload the configuration file
|
||||
bindsym $mod+Shift+c reload
|
||||
# restart i3 inplace (preserves your layout/session, can be used to upgrade i3)
|
||||
bindsym $mod+Shift+r restart
|
||||
# exit i3 (logs you out of your X session)
|
||||
bindsym $mod+Shift+e exec "i3-nagbar -t warning -m 'You pressed the exit shortcut. Do you really want to exit i3? This will end your X session.' -b 'Yes, exit i3' 'i3-msg exit'"
|
||||
|
||||
# resize window (you can also use the mouse for that)
|
||||
mode "resize" {
|
||||
# These bindings trigger as soon as you enter the resize mode
|
||||
|
||||
# Pressing left will shrink the window’s width.
|
||||
# Pressing right will grow the window’s width.
|
||||
# Pressing up will shrink the window’s height.
|
||||
# Pressing down will grow the window’s height.
|
||||
bindsym h resize shrink width 10 px or 10 ppt
|
||||
bindsym j resize grow height 10 px or 10 ppt
|
||||
bindsym k resize shrink height 10 px or 10 ppt
|
||||
bindsym l resize grow width 10 px or 10 ppt
|
||||
|
||||
# same bindings, but for the arrow keys
|
||||
bindsym Left resize shrink width 10 px or 10 ppt
|
||||
bindsym Down resize grow height 10 px or 10 ppt
|
||||
bindsym Up resize shrink height 10 px or 10 ppt
|
||||
bindsym Right resize grow width 10 px or 10 ppt
|
||||
|
||||
# back to normal: Enter or Escape
|
||||
bindsym Return mode "default"
|
||||
bindsym Escape mode "default"
|
||||
}
|
||||
|
||||
bindsym $mod+r mode "resize"
|
||||
|
||||
# Window colors
|
||||
set $border #1d2021
|
||||
set $bg-color #4c6886
|
||||
set $inactive-bg-color #1d2021
|
||||
set $text-color #8a8a8a
|
||||
set $inactive-text-color #8a8a8a
|
||||
set $urgent-bg-color #73aa4f
|
||||
set $indicator #396886
|
||||
|
||||
# window colors
|
||||
# border background text indicator
|
||||
client.focused $border $bg-color $text-color $indicator
|
||||
client.unfocused $inactive-bg-color $inactive-bg-color $text-color $border
|
||||
client.focused_inactive $inactive-bg-color $inactive-bg-color $text-color $border
|
||||
client.urgent $urgent-bg-color $urgent-bg-color $text-color #F92672
|
||||
|
||||
# Start i3bar to display a workspace bar (plus the system information i3status
|
||||
# finds out, if available)
|
||||
bar {
|
||||
position top
|
||||
status_command i3status
|
||||
colors {
|
||||
background $inactive-bg-color
|
||||
separator #757575
|
||||
statusline $text-color
|
||||
# border background text
|
||||
focused_workspace $bg-color $bg-color $text-color
|
||||
inactive_workspace $inactive-bg-color $inactive-bg-color $text-color
|
||||
urgent_workspace $urgent-bg-color $urgent-bg-color $text-color
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
# Keybindings for brightness Mac
|
||||
bindsym XF86MonBrightnessUp exec xbacklight -inc 10 # increase screen brightness
|
||||
bindsym XF86MonBrightnessDown exec xbacklight -dec 10 # decrease screen brightness
|
||||
|
||||
# lockscreen (make sure to scrot that desktop boi)
|
||||
bindsym $mod+$mod1+l exec i3lock -i $HOME/Pictures/lock.png
|
||||
|
||||
# Fix for "Natural Scrolling"
|
||||
exec synclient HorizEdgeScroll=1 VertEdgeScroll=1 VertScrollDelta=-111
|
||||
|
||||
# Background stored as wallpaper.png
|
||||
exec feh --bg-scale $HOME/Pictures/wallpaper.jpg
|
||||
|
||||
# Keybindings for audio up/down and mute Mac
|
||||
bindsym XF86AudioRaiseVolume exec pactl set-sink-volume 0 +5% #increase sound volume
|
||||
bindsym XF86AudioLowerVolume exec pactl set-sink-volume 0 -5% #DECREASE SOUND VOLUMe
|
||||
bindsym XF86AudioMute exec pactl set-sink-mute 0 toggle # mute sound
|
||||
# Playerctl stuff
|
||||
bindsym XF86AudioPlay exec playerctl play-pause # Play or Pause
|
||||
bindsym XF86AudioNext exec playerctl next # Next Song
|
||||
bindsym XF86AudioPrev exec playerctl previous # Next Song
|
||||
bindsym XF86Tools [class="Spotify"] scratchpad show
|
||||
|
||||
# No title bars
|
||||
for_window [class="^.*"] border pixel 2
|
||||
for_window [title="^.*"] border pixel 2
|
||||
for_window [id="^.*"] border pixel 2
|
||||
|
||||
# Scratchpad
|
||||
bindsym $mod+apostrophe move scratchpad
|
||||
#bindsym $mod+semicolon [class="Spotify"] scratchpad show
|
||||
bindsym $mod+semicolon [instance="music"] scratchpad show
|
||||
bindsym $mod+period [class="teams-for-linux"] scratchpad show
|
||||
bindsym $mod+slash [class="Slack"] scratchpad show
|
||||
bindsym $mod+backslash scratchpad show
|
||||
|
||||
bindsym $mod+Shift+semicolon exec $ns urxvt -name music -e ncmpcpp
|
||||
exec $ns urxvt -name music -e ncmpcpp
|
||||
|
||||
# Make certain windows always floating
|
||||
for_window [title="Simulink Library Browser"] floating enable
|
||||
for_window [class="Teams for Linux"] floating enable
|
||||
for_window [class="Slack"] floating enable
|
||||
|
||||
# Swap caps and ctrl
|
||||
exec setxkbmap -option ctrl:nocaps
|
||||
|
||||
bindsym $mod+ctrl+l move workspace to output right
|
||||
bindsym $mod+ctrl+h move workspace to output left
|
||||
|
||||
# Switch back and forth
|
||||
workspace_auto_back_and_forth yes
|
||||
|
||||
exec --no-startup-id xset r rate 300 20 # Set initial delay 300ms, repeat 20ms
|
||||
|
||||
exec --no-startup-id nm-applet
|
||||
|
||||
# Gaps if i3-gaps is installed
|
||||
gaps inner 10
|
||||
smart_gaps on
|
|
@ -1,3 +1,7 @@
|
|||
# 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, ... }:
|
||||
|
||||
{
|
||||
|
@ -6,16 +10,9 @@
|
|||
./hardware-configuration.nix
|
||||
];
|
||||
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
|
||||
# Use the GRUB 2 boot loader.
|
||||
boot.loader.grub.enable = true;
|
||||
boot.loader.grub.version = 2;
|
||||
# boot.loader.grub.efiSupport = true;
|
||||
# boot.loader.grub.efiInstallAsRemovable = true;
|
||||
# boot.loader.efi.efiSysMountPoint = "/boot/efi";
|
||||
# Define on which hard drive you want to install Grub.
|
||||
boot.loader.grub.device = "/dev/sda"; # or "nodev" for efi only
|
||||
# Bootloader.
|
||||
boot.loader.systemd-boot.enable = true;
|
||||
boot.loader.efi.canTouchEfiVariables = true;
|
||||
|
||||
networking.hostName = "nixos"; # Define your hostname.
|
||||
# networking.wireless.enable = true; # Enables wireless support via wpa_supplicant.
|
||||
|
@ -24,92 +21,150 @@
|
|||
# networking.proxy.default = "http://user:password@proxy:port/";
|
||||
# networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain";
|
||||
|
||||
# Select internationalisation properties.
|
||||
# i18n = {
|
||||
# consoleFont = "Lat2-Terminus16";
|
||||
# consoleKeyMap = "us";
|
||||
# defaultLocale = "en_US.UTF-8";
|
||||
# };
|
||||
# Enable networking
|
||||
networking.networkmanager.enable = true;
|
||||
|
||||
# Set your time zone.
|
||||
time.timeZone = "Europe/Copenhagen";
|
||||
|
||||
# List packages installed in system profile. To search, run:
|
||||
# $ nix search wget
|
||||
environment.systemPackages = with pkgs; [
|
||||
wget
|
||||
vim
|
||||
firefox
|
||||
thunderbird
|
||||
git
|
||||
python3
|
||||
rxvt_unicode_with-plugins
|
||||
# Select internationalisation properties.
|
||||
i18n.defaultLocale = "en_GB.UTF-8";
|
||||
|
||||
mosh
|
||||
woof # share files over http on localhost
|
||||
i18n.extraLocaleSettings = {
|
||||
LC_ADDRESS = "da_DK.UTF-8";
|
||||
LC_IDENTIFICATION = "da_DK.UTF-8";
|
||||
LC_MEASUREMENT = "da_DK.UTF-8";
|
||||
LC_MONETARY = "da_DK.UTF-8";
|
||||
LC_NAME = "da_DK.UTF-8";
|
||||
LC_NUMERIC = "da_DK.UTF-8";
|
||||
LC_PAPER = "da_DK.UTF-8";
|
||||
LC_TELEPHONE = "da_DK.UTF-8";
|
||||
LC_TIME = "da_DK.UTF-8";
|
||||
};
|
||||
|
||||
# terminal tools
|
||||
gotop
|
||||
cava
|
||||
|
||||
];
|
||||
|
||||
networking.networkmanager.enable = true;
|
||||
|
||||
# Enable sound.
|
||||
sound.enable = true;
|
||||
hardware.pulseaudio.enable = true;
|
||||
nix.settings.trusted-users = [ "root" "valberg" ];
|
||||
nix.settings.experimental-features = [ "nix-command" "flakes" ];
|
||||
|
||||
# Enable the X11 windowing system.
|
||||
#services.xserver.enable = true;
|
||||
# services.xserver.layout = "us";
|
||||
# services.xserver.xkbOptions = "eurosign:e";
|
||||
|
||||
# Enable touchpad support.
|
||||
#services.xserver.libinput.enable = true;
|
||||
services.xserver.enable = true;
|
||||
|
||||
# Enable the GNOME Desktop Environment.
|
||||
#services.xserver.displayManager.gdm.enable = true;
|
||||
#services.xserver.desktopManager.gnome3.enable = true;
|
||||
#nixpkgs.config.firefox.enableGnomeExtensions = true;
|
||||
#services.gnome3.chrome-gnome-shell.enable = true;
|
||||
services.xserver.displayManager.gdm.enable = true;
|
||||
services.xserver.desktopManager.gnome.enable = true;
|
||||
|
||||
# Configure keymap in X11
|
||||
services.xserver = {
|
||||
xkb.layout = "us";
|
||||
xkb.variant = "altgr-intl";
|
||||
xkb.options = "ctrl:swapcaps";
|
||||
};
|
||||
|
||||
# Enable CUPS to print documents.
|
||||
services.printing.enable = true;
|
||||
|
||||
# Enable sound with pipewire.
|
||||
sound.enable = true;
|
||||
hardware.pulseaudio.enable = false;
|
||||
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;
|
||||
|
||||
xkbOptions = "ctrl:swapcaps";
|
||||
layout = "us";
|
||||
xkbVariant = "intl";
|
||||
|
||||
desktopManager = {
|
||||
default = "none";
|
||||
xterm.enable = false;
|
||||
# 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;
|
||||
};
|
||||
|
||||
windowManager.i3 = {
|
||||
# Enable touchpad support (enabled default in most desktopManager).
|
||||
# services.xserver.libinput.enable = true;
|
||||
|
||||
|
||||
virtualisation.docker.enable = true;
|
||||
virtualisation.docker.rootless = {
|
||||
enable = true;
|
||||
package = pkgs.i3-gaps;
|
||||
extraPackages = with pkgs; [
|
||||
dmenu
|
||||
i3status
|
||||
i3lock
|
||||
dunst
|
||||
polybar
|
||||
];
|
||||
};
|
||||
setSocketVariable = true;
|
||||
};
|
||||
|
||||
programs.fish.enable = true;
|
||||
|
||||
# Define a user account. Don't forget to set a password with ‘passwd’.
|
||||
users.users.valberg = {
|
||||
isNormalUser = true;
|
||||
extraGroups = [ "wheel" "networkmanager" ];
|
||||
description = "Vidir Valberg Gudmundsson";
|
||||
extraGroups = [ "networkmanager" "wheel" "docker" ];
|
||||
shell = pkgs.fish;
|
||||
packages = with pkgs; [
|
||||
firefox
|
||||
thunderbird
|
||||
keepassxc
|
||||
jetbrains.pycharm-professional
|
||||
slack
|
||||
gnome.gnome-tweaks
|
||||
deja-dup
|
||||
signal-desktop
|
||||
tmux
|
||||
obsidian
|
||||
element-desktop
|
||||
discord
|
||||
pyenv
|
||||
nerdfonts
|
||||
blackbox-terminal
|
||||
ripgrep
|
||||
pre-commit
|
||||
spotify
|
||||
];
|
||||
};
|
||||
|
||||
# This value determines the NixOS release with which your system is to be
|
||||
# compatible, in order to avoid breaking some software such as database
|
||||
# servers. You should change this only after NixOS release notes say you
|
||||
# should.
|
||||
system.stateVersion = "19.03"; # Did you read the comment?
|
||||
nixpkgs.config.permittedInsecurePackages = [
|
||||
"electron-25.9.0"
|
||||
];
|
||||
|
||||
# Allow unfree packages
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
|
||||
# List packages installed in system profile. To search, run:
|
||||
# $ nix search wget
|
||||
environment.systemPackages = with pkgs; [
|
||||
# vim # Do not forget to add an editor to edit configuration.nix! The Nano editor is also installed by default.
|
||||
# wget
|
||||
vim
|
||||
git
|
||||
git-lfs
|
||||
python310Packages.pip
|
||||
python311Packages.pip
|
||||
file
|
||||
nodejs
|
||||
];
|
||||
|
||||
# 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. It‘s 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 = "23.11"; # Did you read the comment?
|
||||
|
||||
}
|
||||
|
|
48
flake.lock
Normal file
48
flake.lock
Normal file
|
@ -0,0 +1,48 @@
|
|||
{
|
||||
"nodes": {
|
||||
"home-manager": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1708591310,
|
||||
"narHash": "sha256-8mQGVs8JccWTnORgoLOTh9zvf6Np+x2JzhIc+LDcJ9s=",
|
||||
"owner": "nix-community",
|
||||
"repo": "home-manager",
|
||||
"rev": "0e0e9669547e45ea6cca2de4044c1a384fd0fe55",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-community",
|
||||
"repo": "home-manager",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1708475490,
|
||||
"narHash": "sha256-g1v0TsWBQPX97ziznfJdWhgMyMGtoBFs102xSYO4syU=",
|
||||
"owner": "nixos",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "0e74ca98a74bc7270d28838369593635a5db3260",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nixos",
|
||||
"ref": "nixos-unstable",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"root": {
|
||||
"inputs": {
|
||||
"home-manager": "home-manager",
|
||||
"nixpkgs": "nixpkgs"
|
||||
}
|
||||
}
|
||||
},
|
||||
"root": "root",
|
||||
"version": 7
|
||||
}
|
37
flake.nix
Normal file
37
flake.nix
Normal file
|
@ -0,0 +1,37 @@
|
|||
{
|
||||
description = "My NixOS configuration";
|
||||
|
||||
inputs = {
|
||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
||||
home-manager = {
|
||||
url = github:nix-community/home-manager;
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
};
|
||||
|
||||
outputs = { nixpkgs, home-manager, ... }:
|
||||
let
|
||||
system = "x86_64-linux";
|
||||
pkgs = nixpkgs.legacyPackages.${system};
|
||||
in {
|
||||
|
||||
nixosConfigurations = {
|
||||
nixos = nixpkgs.lib.nixosSystem {
|
||||
inherit system;
|
||||
modules = [
|
||||
./configuration.nix
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
homeConfigurations = {
|
||||
valberg = home-manager.lib.homeManagerConfiguration {
|
||||
inherit pkgs;
|
||||
modules = [
|
||||
./home-manager/home.nix
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
};
|
||||
}
|
40
hardware-configuration.nix
Normal file
40
hardware-configuration.nix
Normal file
|
@ -0,0 +1,40 @@
|
|||
# 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 = [ "nvme" "xhci_pci" "usb_storage" "sd_mod" ];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ "kvm-amd" ];
|
||||
boot.extraModulePackages = [ ];
|
||||
|
||||
fileSystems."/" =
|
||||
{ device = "/dev/disk/by-uuid/dd2b841b-7000-4d8d-ba8b-698b153cb71f";
|
||||
fsType = "ext4";
|
||||
};
|
||||
|
||||
fileSystems."/boot" =
|
||||
{ device = "/dev/disk/by-uuid/59FD-2C19";
|
||||
fsType = "vfat";
|
||||
};
|
||||
|
||||
swapDevices =
|
||||
[ { device = "/dev/disk/by-uuid/b369b7fe-f757-4078-b7de-cc191102afc6"; }
|
||||
];
|
||||
|
||||
# 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.enp1s0f0.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.wlp2s0.useDHCP = lib.mkDefault true;
|
||||
|
||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||
hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||
}
|
17
home-manager/home.nix
Normal file
17
home-manager/home.nix
Normal file
|
@ -0,0 +1,17 @@
|
|||
{ config, pkgs, ... }:
|
||||
|
||||
{
|
||||
programs.home-manager.enable = true;
|
||||
home.username = "valberg";
|
||||
home.homeDirectory = "/home/valberg";
|
||||
home.stateVersion = "23.11";
|
||||
|
||||
home.packages = with pkgs; [
|
||||
ansible
|
||||
python311Packages.tox
|
||||
python311Packages.virtualenv
|
||||
pipx
|
||||
zoxide
|
||||
];
|
||||
|
||||
}
|
Loading…
Reference in a new issue