diff --git a/flake.lock b/flake.lock index b253720..e2e2c3d 100644 --- a/flake.lock +++ b/flake.lock @@ -7,11 +7,11 @@ ] }, "locked": { - "lastModified": 1684157850, - "narHash": "sha256-xGHTCgvAxO5CgAL6IAgE/VGRX2wob2Y+DPyqpXJ32oQ=", + "lastModified": 1685189510, + "narHash": "sha256-Hq5WF7zIixojPgvhgcd6MBvywwycVZ9wpK/8ogOyoaA=", "owner": "nix-community", "repo": "home-manager", - "rev": "c0deab0effd576e70343cb5df0c64428e0e0d010", + "rev": "2d963854ae2499193c0c72fd67435fee34d3e4fd", "type": "github" }, "original": { @@ -22,11 +22,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1684139381, - "narHash": "sha256-YPLMeYE+UzxxP0qbkBzv3RBDvyGR5I4d7v2n8dI3+fY=", + "lastModified": 1684935479, + "narHash": "sha256-6QMMsXMr2nhmOPHdti2j3KRHt+bai2zw+LJfdCl97Mk=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "17a689596b72d1906883484838eb1aaf51ab8001", + "rev": "f91ee3065de91a3531329a674a45ddcb3467a650", "type": "github" }, "original": { diff --git a/flake.nix b/flake.nix index a146bb0..3612097 100644 --- a/flake.nix +++ b/flake.nix @@ -1,6 +1,11 @@ { description = "First stab at a flake for my system config"; + # nix = { + # gc.automatic = true; + # optimize.automatic = true; + # }; + inputs = { nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable"; home-manager.url = "github:nix-community/home-manager"; diff --git a/home/default.nix b/home/default.nix index 8742db5..453f836 100644 --- a/home/default.nix +++ b/home/default.nix @@ -5,12 +5,6 @@ home.homeDirectory = "/home/till"; home.stateVersion = "22.11"; - home.pointerCursor = { - name = "Adwaita"; - package = pkgs.gnome.adwaita-icon-theme; - size = 32; - }; - nixpkgs = { config = { allowUnfree = true; @@ -20,6 +14,16 @@ programs.home-manager.enable = true; + xdg.userDirs = { + enable = true; + createDirectories = true; + download = "${config.home.homeDirectory}/tmp"; + music = "${config.home.homeDirectory}/media/music"; + pictures = "${config.home.homeDirectory}/media/img"; + videos = "${config.home.homeDirectory}/media/vid"; + documents = "${config.home.homeDirectory}/misc"; + }; + services.syncthing.enable = true; home.packages = with pkgs; [ @@ -70,6 +74,7 @@ qutebrowser nyxt vlc + chromium # deveolopment bundix @@ -90,6 +95,7 @@ ./mail ./tex.nix ./openconnect.nix + ./desktop ]; home.shellAliases = { diff --git a/home/desktop/default.nix b/home/desktop/default.nix new file mode 100644 index 0000000..4fe5de7 --- /dev/null +++ b/home/desktop/default.nix @@ -0,0 +1,20 @@ +{ config, pkgs, ... }: + +{ + home.pointerCursor = { + name = "Adwaita"; + package = pkgs.gnome.adwaita-icon-theme; + size = 32; + }; + + dconf.settings = { + "org/gnome/desktop/background" = { + picture-uri = ./demand_office.jpg; + }; + enabled-extensions = { + "run-or-raise@edvard.cz" + "places-menu@gnome-shell-extensions.gcampax.github.com" + } + }; + xdg.configFile."run-or-raise/shortcuts.conf".source = ./run-or-raise.conf; +} diff --git a/home/desktop/demand_office.jpg b/home/desktop/demand_office.jpg new file mode 100644 index 0000000..b848e38 Binary files /dev/null and b/home/desktop/demand_office.jpg differ diff --git a/home/desktop/run-or-raise.conf b/home/desktop/run-or-raise.conf new file mode 100644 index 0000000..2361354 --- /dev/null +++ b/home/desktop/run-or-raise.conf @@ -0,0 +1,42 @@ +# Here you list all the shortcuts. +# +# The shortcuts may be defined in two ways: +# +# 1. Run-or-raise form: shortcut,launch-command,[wm_class],[title] +# * wm_class and title are optional and case sensitive +# * if none is set, lowercased launch-command is compared with lowercased windows wm_classes and titles +# +# 2. Run only form: shortcut,calculate +# +# ================= +# Run or raise form +# ================= +# +# This line cycles any open gnome-terminal (matched by wm_class = Gnome-terminal on Ubuntu 17.10) OR if not found, launches new one. +# If you're using Arch, you may want to match by wm_class = gnome-terminal-server , just check yourself by Alt+F2/lg/Windows +t,gnome-terminal,gnome-terminal-server, +n,nautilus,, +f,firefox,, +return,foot,, +x,keepassxc,,, +q,qutebrowser,, + +# You may use regular expression in title or wm_class. +# Just put the regular expression between slashes. +# E.g. to jump to pidgin conversation window you may use this line +# (that means any windows of wm_class Pidgin, not containing the title Buddy List)" +# KP_1,pidgin,Pidgin,/^((?!Buddy List).)*$/ + +# Have the mail always at numpad-click. +# KP_2,chromium-browser --app=https://mail.google.com/mail/u/0/#inbox + +# ============= +# Run only form +# ============= +# +# This line will launch notify-send command. +# h,notify-send Hello world + +# Blank lines are allowed. Line starting with "#" means a comment. +# Now delete these shortcuts and put here yours. +# How to know wm_class? Alt+f2, lg, "windows" tab (at least on Ubuntu 17.10) diff --git a/system/gnome.nix b/system/gnome.nix index 9e2ee1a..578cf80 100644 --- a/system/gnome.nix +++ b/system/gnome.nix @@ -5,7 +5,18 @@ services.xserver.displayManager.gdm.enable = true; services.xserver.desktopManager.gnome.enable = true; services.gnome.gnome-browser-connector.enable = true; - environment.systemPackages = [ - pkgs.gnome.gnome-tweaks + environment.gnome.excludePackages = (with pkgs; [ + # gnome-photos + gnome-tour + ]) ++ (with pkgs.gnome; [ + epiphany + geary + yelp + gnome-contacts + gnome-initial-setup + ]); + environment.systemPackages = with pkgs.gnome; [ + gnome-tweaks + gedit ]; }