diff --git a/.i3status.conf b/.config/i3status/config similarity index 100% rename from .i3status.conf rename to .config/i3status/config diff --git a/.config/sway/config b/.config/sway/config index 0e104cf..c3cb216 100644 --- a/.config/sway/config +++ b/.config/sway/config @@ -348,7 +348,7 @@ bindsym $mod+space exec "/home/g1smo/bin/get-layout.sh" ### # Fix za pocasen GTK app startup -exec dbus-update-activation-environment --systemd DISPLAY WAYLAND_DISPLAY SWAYSOCK +exec dbus-update-activation-environment --systemd DISPLAY WAYLAND_DISPLAY SWAYSOCK XDG_CURRENT_DESKTOP=sway # transparenca nekativnih oken #exec_always ~/bin/inactive-windows-transparency.py @@ -392,6 +392,8 @@ exec keepassxc # Lebdeca okna (najdes preko "swaymsg -t get_tree") for_window [app_id="org.keepassxc.KeePassXC"] floating enable +for_window [title="^Utopia"] floating enable +for_window [title="^OSCRecorder"] floating enable # Foot terminal server! exec foot --server diff --git a/.emacs.d/config.org b/.emacs.d/config.org index 9211f06..5c021f9 100644 --- a/.emacs.d/config.org +++ b/.emacs.d/config.org @@ -101,13 +101,17 @@ Tukaj se nahajate samo bližnjici za preklop med bufferji (kako bi to lepo preve In pa ukaz za ponovno naložit konfiguracijo emacsa. #+begin_src emacs-lisp - (defun ponovno-nalozi-config () (ineractive) (load-file "~/.emacs.d/init.el")) + (defun ponovno-nalozi-config () + "Ponovno naloži emacs konfiguracijo" + (interactive) + (load-file "~/.emacs.d/init.el")) (start/leader-keys ;; Osnovne bliznjice "[" 'previous-buffer "]" 'next-buffer "r" 'ponovno-nalozi-config + "u" 'font-lock-update ) #+end_src @@ -167,8 +171,7 @@ Bližnjice za delo z datotekami se začnejo s ~f~. #+begin_src emacs-lisp (defun odpri-konfiguracijo () (interactive) (find-file "~/.emacs.d/config.org")) (defun odpri-init () (interactive) (find-file "~/.emacs.d/init.el")) - (defun odpri-todo () (interactive) (find-file "~/org/todo.org")) - (defun odpri-zapiske () (interactive) (find-file "~/org/zapiski.org")) + (defun odpri-todo () (interactive) (find-file "~/org/TODO.org")) (start/leader-keys "f" '(:ignore t :wk "file") @@ -193,6 +196,14 @@ Emacs nudi kup uporabnih funkcij, ki so nepogrešljive na poti učenja o funkcio "d m" 'describe-mode) #+end_src +** Info +Branje navodil, SICP, še kaj. + +#+begin_src emacs-lisp + (start/leader-keys + "i" 'info) +#+end_src + ** Konec Dodamo manjkajoči zaklepaj. :) @@ -208,16 +219,18 @@ Ta sekcija vsebuje razne konfiguracije povezane z ~evil-mode~ - modalnim načino Vklopi evil mode! +~evil-shift-width~ nastavi širino tabulacije ko pritisnemo ~>~ + #+begin_src emacs-lisp (setq evil-want-integration t - evil-want-keybinding nil) + evil-want-keybinding nil + evil-shift-width 2) ;org-return-follows-link t (require 'evil) (evil-mode 1) #+end_src Paket ~evil-collection~ pa vsebuje še dodatne evil bližnjice (recimo za ~help-mode~, ~eshell~ in tako dalje). - #+begin_src emacs-lisp (use-package evil-collection @@ -261,6 +274,32 @@ Evil v ~treemacs~ drevesu datotečnega sistema. #+end_src * Emacs splošno +** Dashboard +Prvi zaslon ob zagonu (~homescreen~), prikaže uporabne stvari. + +#+begin_src emacs-lisp + (use-package dashboard + :general + (start/leader-keys + "b h" 'dashboard-open) + :after nerd-icons + :init + (dashboard-setup-startup-hook) + (setq initial-buffer-choice (lambda () (get-buffer-create "*dashboard*"))) + (setq dashboard-banner-logo-title "EMA☭S") + (setq dashboard-startup-banner 3) + (setq dashboard-center-content t) + (setq dashboard-items '((agenda . 5) + (bookmarks . 3) + (recents . 5))) + ;(setq dashboard-display-icons-p t) ;; display icons on both GUI and terminal + ;(setq dashboard-icon-type 'nerd-icons) ;; use `nerd-icons' package + (setq dashboard-set-heading-icons t) + (setq dashboard-set-file-icons t) + (setq dashboard-set-navigator t) + (setq dashboard-set-init-info t)) +#+end_src + ** Vertico dopolnjevanje Paket za dopolnjevanje, nadomestek ~ivy~. Nudi nekoliko lepšo iskušnjo priporočil pri izvajanju emacs ukazov. @@ -299,7 +338,8 @@ Paket za dopolnjevanje, nadomestek ~ivy~. Nudi nekoliko lepšo iskušnjo priporo ~nerd-icons-completion~ nam dired in ostalo dopolnjevanje pojača z ikonami. #+begin_src emacs-lisp - ;(use-package nerd-icons-completion :init (nerd-icons-completion-mode)) + (use-package nerd-icons-completion + :init (nerd-icons-completion-mode)) #+end_src ** Iskanje @@ -433,6 +473,39 @@ PDF dokumenti so včasih zelo veliki, raje jih odpirajmo s sistemskim preglejeva (openwith-mode t)) #+end_src +** Lepši REPL (ielm) +Nekoliko bolj prijazen elisp REPL, ki ima med drugim zgodovino. + +#+begin_src emacs-lisp + (defun g-ielm-init-history () + "Obstojna ielm zgodovina." + (let ((path (expand-file-name "ielm/history" user-emacs-directory))) + (make-directory (file-name-directory path) t) + (setq-local comint-input-ring-file-name path)) + (setq-local comint-input-ring-size 10000) + (setq-local comint-input-ignoredups t) + (comint-read-input-ring)) + (defun g-ielm-write-history (&rest _args) + "Tole je povezano z obstojno ielm zgodovino." + (with-file-modes #o600 + (comint-write-input-ring))) + (use-package ielm + :defer t + :hook (ielm-mode-hook . (lambda () + (eldoc-mode) + ;(paredit-mode) + (g-ielm-init-history))) + :general + (start/leader-keys + ";" 'ielm) + :config + (advice-add 'ielm-send-input :after 'g-ielm-write-history) + (define-key inferior-emacs-lisp-mode-map (kbd "C-l") + 'comint-clear-buffer) + (define-key inferior-emacs-lisp-mode-map (kbd "C-r") + 'helm-comint-input-ring)) +#+end_src + * ORG Orgmode je način, v katerem je spisan tale dokument. Orgmode je marsikaj, lahko bi ga pa strnili v razširitev navadnega (plain) teksta. @@ -455,7 +528,8 @@ TODO dodaj več! (start/leader-keys :keymaps 'org-mode-map "o i" 'org-toggle-inline-images - "o t" 'org-time-stamp) + "o t" 'org-time-stamp + "o r" 'org-refile) #+end_src V org dokumente lahko vnašamo bloke vsebin, kot so programska koda, citati in podobno. Privzeto to dosežemo s ~C-c C-,~ in izbiro vrste željenega bloka, s sledečo konfiguracijo pa vklopimo bližnjico; na prazni vrstici samo "~ to jump to first/last slide +- ~C-c C-r~ for buffer read-only +- ~C-c C-w~ for buffer read/write +- ~C-c C-1~ for one big page showing all slides +#+begin_src emacs-lisp + (use-package org-present :after org-mode :defer t) +#+end_src + + +#+begin_src emacs-lisp + (use-package htmlize :after org-mode :defer t) +#+end_src +* Grafični vmesnik + Barvna tema je [[https://github.com/greduan/emacs-theme-gruvbox][gruvbox]], v varjanti ~gruvbox-dark-soft~, s pisavo Iosevka. #+begin_src emacs-lisp @@ -658,9 +752,6 @@ Uporabimo nerd ikone. ~POZOR~ pisavo naložimo z ukazom ~M-x nerd-icons-install- #+begin_src emacs-lisp (use-package nerd-icons) - - ; Rabimo tudi all the icons? - ;(use-package all-the-icons) #+end_src ** Drsenje (skrolanje) @@ -750,7 +841,17 @@ In pa nenazadnje, čeravno je ORGMODE superioren, naložimo še podporo za [[htt * GNU/Guix #+begin_src emacs-lisp - (use-package guix :ensure f) + (use-package guix :ensure f :defer t) +#+end_src + +** Pretty SHA path +Minor mode, ki SHA hashe v bufferju skrajša in tako poveča preglednost. + +#+begin_src emacs-lisp + (use-package pretty-sha-path + :ensure t + :config + (pretty-sha-path-global-mode)) #+end_src * Delo s projekti @@ -790,6 +891,15 @@ Datoteke sortiraj glede na nedavno uporabljene bufferje in nato nedavno odprte. (use-package counsel-projectile :after projectile) #+end_src +~org-projectile~ omogoča vzdrževanje ORG TODO list na posameznih projektih. +#+begin_src emacs-lisp + (use-package org-projectile :after projectile) +#+end_src + +#+begin_src + +#+end_src + ** Oblikovanje teksta [[https://editorconfig.org/][Editorconfig]] omogoča nastavljanje oblikovanje tekstovnih fajlov na ravni posameznega projekta. @@ -824,6 +934,7 @@ Za začetek nastavimo uporabo dveh navadnih presledkov za tab zamik. #+begin_src emacs-lisp (setq-default tab-width 2) (setq-default indent-tabs-mode nil) + (setq indent-line-function 'insert-tab) #+end_src Vklopimo avtomatsko zapiranje oklepajev ter emacsovo avtomatsko zamikanje. @@ -1009,8 +1120,11 @@ Dodamo še pripadajoč paket za olepševanje kode (avtomatsko prilagoditev zamik #+begin_src emacs-lisp (use-package web-mode - :config (setq web-mode-markup-indent-offset 2) - :mode "\\.(html|twig)\\'") + :mode "\\.(html|twig)\\'" + :custom + (web-mode-markup-indent-offset 2) + (web-mode-css-indent-offset 2) + (web-mode-code-indent-offset 2)) (use-package web-beautify :after web-mode) #+end_src @@ -1144,21 +1258,37 @@ Nastavljen naj bo na ~python3~. Najprej moramo vključit direktorij, v katerem se nahajajo emacs paketi zanj (pridejo iz v supercolliderju nameščenega [[https://github.com/supercollider/scel][quarka]]), lahko bi pra prišel iz paketnega upravljalnika linux distribucije ali pa MELPE: #+begin_src emacs-lisp - ;(add-to-list 'load-path "~/.local/share/SuperCollider/downloaded-quarks/scel/el") + (add-to-list 'load-path "~/.local/share/SuperCollider/scel/el") +; (add-to-list 'load-path "~/.guix-profile/share/emacs/site-lisp/scel-20170629-1.aeea3ad") #+end_src -Nato vključimo emacs modul in nastavimo dve bližnjici; ~S-RET~ za evalviranje trenutne regije ali vrstice ter ~C-.~ za utišanje (kot v IDE-ju). +Nato vključimo emacs modul ter [[https://github.com/yilin-zhang/sclang-helper][sclang-helper]] za lažjo evalvacijo kode in nastavimo bližnjice; ~C-RET~ za evalviranje "trenutne regije" (med zunanjimi oklepaji), ~C-c C-c~ za evalvacijo vrstice ali izbrane regije ter ~C-.~ za utišanje (kot v IDE-ju). #+begin_src emacs-lisp - ;(require 'sclang) - ;(global-set-key (kbd "S-RET") 'sclang-eval-region-or-line) - ;(global-set-key (kbd "C-.") 'sclang-server-free-all) + (require 'sclang) + + ;; Za branje dokumentacije + (use-package sclang-extensions + :config + (load "~/.emacs.d/sclang-helper.el") + (add-hook 'sclang-mode-hook 'sclang-extensions-mode) + (add-hook 'sclang-mode-hook (lambda () (local-set-key (kbd "C-") 'sclang-helper-eval-paren-region)))) #+end_src -Prilagam še kodo uporabnih funkcij za lažjo evalvacijo kode, [[https://github.com/yilin-zhang/sclang-helper][sclang-helper]] +Za branje supercollider dokumentacije potrebujemo še ~w3m~ paket. #+begin_src emacs-lisp - ;(load "~/.emacs.d/sclang-helper.el") + (use-package w3m :defer t) +#+end_src + +Povozimo drug keybinding. + +#+begin_src emacs-lisp + (use-package bind-key + :defer t + :init + (bind-key "C-c C-c" 'sclang-helper-eval-region-or-line sclang-extensions-mode-map) + (bind-key* "C-." 'sclang-server-free-all sclang-extensions-mode-map)) #+end_src [[http://www.pawfal.org/Software/fluxus_/][fluxus]] je programsko okolje za hitro prototipiranje ter igranje z oz. učenje 3d grafike. Pisam je v schemu. @@ -1258,6 +1388,31 @@ S sledečimi nastavitvami pospešimo delovanje. (setq read-process-output-max (* 1024 1024))) ;; 1mb #+end_src +** Clojure + +~clojure-mode~ za obarvanje in podobno + +#+begin_src emacs-lisp +(use-package clojure-mode) +#+end_src + +~CIDER~ integrira clojure repl. + +#+begin_src emacs-lisp +(use-package cider + :general + (start/leader-keys + :keymaps clojure-mode-map + ;; EVAL ukazi + "e" '(:ignore t :wk "eval") + "e b" 'cider-eval-buffer + "e e" 'cider-eval-dwim + "e r" 'cider-eval-region + "b e" 'cider-eval-buffer) + :config + (add-hook 'clojure-mode-hook (lambda () (local-set-key (kbd "C-") 'cider-eval-last-sexp)))) +#+end_src + * E-pošta Emacs že vključuje ~mu4e~ ([[https://www.djcbsoftware.nl/code/mu/][mu]] za emacs), modul ki omogoča brskanje po prejeti e-pošti. @@ -1265,8 +1420,8 @@ Pred uporabo je treba konfigurirati nekaj več stvari, potrebujemo recimo ~isync ** Prejemanje *** isync - **** Namestitev + Najprej namestimo isync. Primer za guix ter debian. #+begin_src sh @@ -1275,6 +1430,7 @@ Najprej namestimo isync. Primer za guix ter debian. #+end_src **** Konfiguracija + Konfiguriramo ga v ~~/.mbsyncrc~. Primer je za dva poštna nabiralnika, ki bosta shranjena znotraj ~~/.mail~. #+begin_src @@ -1419,6 +1575,7 @@ Pedenanje izgleda: - system crafters o emacs emailu: https://www.youtube.com/watch?v=yZRyEhi4y44&list=PLEoMzSkcN8oM-kA19xOQc8s0gr0PpFGJQ ** Pošiljanje + #+begin_src emacs-lisp (require 'smtpmail) (setq send-mail-function 'smtpmail-send-it diff --git a/.emacs.d/init.el b/.emacs.d/init.el index 809d83c..c841676 100644 --- a/.emacs.d/init.el +++ b/.emacs.d/init.el @@ -6,6 +6,15 @@ (setq warning-minimum-level :error) +;; Error in pre-command-hook (vertico--prepare): (void-function compat--completion-metadata-get) +;(let ((regex "compat--completion-metadata-get")) +; (->> (elisp-load-path-roots) +; (-filter #'file-exists-p) +; (mapcar #'shell-quote-argument) +; (append `("grep" "-R" ,(shell-quote-argument regex))) +; (funcall (-flip #'string-join) " ") +; (grep-find))) + ;;; Code: (org-babel-load-file "~/.emacs.d/config.org") @@ -20,6 +29,7 @@ ; :defer t ; :config ; (rg-enable-default-bindings)) + ;; ELISP test (defun odpri-dnevnik () @@ -32,56 +42,6 @@ "ŠE VEČ TEKSTA!" "\n"))) (global-set-key (kbd "C-M-d") 'odpri-dnevnik) -;; GNU guix -(use-package guix :defer t) - -;; Dashboard - homescreen -(use-package dashboard - :general - (start/leader-keys - "b h" 'dashboard-open) - ;:after nerd-icons - :init - (dashboard-setup-startup-hook) - (setq initial-buffer-choice (lambda () (get-buffer-create "*dashboard*"))) - (setq dashboard-banner-logo-title "EMA☭S") - (setq dashboard-startup-banner 3) - (setq dashboard-center-content t) - (setq dashboard-items '((agenda . 5) - (recents . 5))) - ;(setq dashboard-display-icons-p t) ;; display icons on both GUI and terminal - ;(setq dashboard-icon-type 'nerd-icons) ;; use `nerd-icons' package - (setq dashboard-set-heading-icons t) - (setq dashboard-set-file-icons t) - (setq dashboard-set-navigator t) - (setq dashboard-set-init-info t)) - -;; Bolj fajni IELM REPL -(defun g-ielm-init-history () - "Obstojna ielm zgodovina." - (let ((path (expand-file-name "ielm/history" user-emacs-directory))) - (make-directory (file-name-directory path) t) - (setq-local comint-input-ring-file-name path)) - (setq-local comint-input-ring-size 10000) - (setq-local comint-input-ignoredups t) - (comint-read-input-ring)) -(defun g-ielm-write-history (&rest _args) - "Tole je povezano z obstojno ielm zgodovino." - (with-file-modes #o600 - (comint-write-input-ring))) -(use-package ielm - :defer t - :hook (ielm-mode-hook . (lambda () - (eldoc-mode) - ;(paredit-mode) - (g-ielm-init-history))) - :config - (advice-add 'ielm-send-input :after 'g-ielm-write-history) - (define-key inferior-emacs-lisp-mode-map (kbd "C-l") - 'comint-clear-buffer) - (define-key inferior-emacs-lisp-mode-map (kbd "C-r") - 'helm-comint-input-ring)) - ;; Sinhronizacija podnapisov (uporablja mpv!) (use-package subed :defer t @@ -106,11 +66,6 @@ (add-hook 'subed-mode-hook 'subed-enable-show-cps)) -(add-to-list 'load-path "~/.local/share/SuperCollider/scel/el") -(require 'sclang) -(global-set-key (kbd "S-RET") 'sclang-eval-region-or-line) -(global-set-key (kbd "C-.") 'sclang-server-free-all) - ;;;;;;;;;;;; ;; CUSTOM ;; ;;;;;;;;;;;; @@ -122,33 +77,34 @@ '(custom-safe-themes '("ba323a013c25b355eb9a0550541573d535831c557674c8d59b9ac6aa720c21d3" default)) + '(helm-minibuffer-history-key "M-p") '(package-selected-packages - '(arduino-mode benchmark-init company counsel-projectile crdt + '(arduino-mode benchmark-init cider company counsel-projectile crdt dashboard diminish direnv doom-modeline drupal-mode editorconfig evil-collection evil-org extempore-mode faceup fluxus-mode flycheck format-all geben geiser-guile general gruvbox-theme guix helm helpful - htmlize jq-mode list-utils loop lsp-mode lsp-ui - magit marginalia mu4e mu4e-dashboard - mu4e-marker-icons nyan-mode ob-mermaid openwith - orderless org-bullets org-caldav paredit pkg-info - popup pos-tip pyvenv racket-mode rainbow-delimiters - restclient rjsx-mode sclang-extensions shut-up sicp - slime smartparens smex subed svg-icon tidal - toml-mode treemacs-projectile treesit-auto undo-tree - use-package vertico vue-mode web-beautify web-mode - which-key writeroom-mode yaml-mode zone-nyan)) + htmlize jq-mode list-utils loop lsp-mode magit + marginalia mu4e mu4e-dashboard mu4e-marker-icons + nyan-mode ob-mermaid openwith orderless org-bullets + org-caldav org-projectile paredit pkg-info pos-tip + pyvenv racket-mode rainbow-delimiters restclient + rjsx-mode sclang-extensions shut-up slime + smartparens smex subed svg-icon tidal toml-mode + treemacs-projectile treesit-auto undo-tree + use-package vertico vue-mode w3m web-beautify + web-mode web-server which-key writeroom-mode + yaml-mode zone-nyan)) '(package-vc-selected-packages '((svg-icon :url "https://github.com/rougier/emacs-svg-icon"))) '(sclang-indent-level 2)) - (custom-set-faces ;; custom-set-faces was added by Custom. ;; If you edit it by hand, you could mess it up, so be careful. ;; Your init file should contain only one such instance. ;; If there is more than one, they won't work right. - '(org-document-title ((t (:inherit default :weight bold :family "Sans Serif" :height 2.0 :underline nil)))) - '(org-level-1 ((t (:inherit default :weight bold :family "Sans Serif" :height 1.75)))) - '(org-level-2 ((t (:inherit default :weight bold :family "Sans Serif" :height 1.45)))) - '(org-level-3 ((t (:inherit default :weight bold :family "Sans Serif" :height 1.25)))) - '(org-level-4 ((t (:inherit default :weight bold :family "Sans Serif" :height 1.1))))) + '(org-document-title ((t (:inherit default :weight bold :font "Verdana" :height 2.0 :underline nil)))) + '(org-level-1 ((t (:inherit default :weight bold :font "Verdana" :height 1.75)))) + '(org-level-2 ((t (:inherit default :weight bold :font "Verdana" :height 1.45)))) + '(org-level-3 ((t (:inherit default :weight bold :font "Verdana" :height 1.25)))) + '(org-level-4 ((t (:inherit default :weight bold :font "Verdana" :height 1.1))))) diff --git a/.zprofile b/.zprofile index 3b3a640..b75062b 100644 --- a/.zprofile +++ b/.zprofile @@ -50,7 +50,7 @@ export XDG_CURRENT_DESKTOP=sway # Guix export GUIX_PROFILE="$HOME/.guix-profile" -export GUIX_PACKAGE_PATH="$HOME/projekti/guix-paketi" +export GUIX_PACKAGE_PATH="$HOME/projekti/kompot/guix-kompot:$HOME/projekti/guix-paketi" if [[ -d "$HOME/.cargo" ]]; then . "$HOME/.cargo/env" diff --git a/.zshrc b/.zshrc index 678bbc3..3e8ff8c 100644 --- a/.zshrc +++ b/.zshrc @@ -146,7 +146,7 @@ alias ustvari-drupal="composer create-project drupal/recommended-project " # Za LXD! if command -v go &> /dev/null; then - export PATH="${PATH}:$(go env GOPATH)/bin:/sbin:/usr/sbin" + export PATH="${PATH}:$(go env GOPATH)/bin" fi #export LD_LIBRARY_PATH="$(go env GOPATH)/deps/dqlite/.libs/:$(go env GOPATH)/deps/raft/.libs/:${LD_LIBRARY_PATH}" @@ -161,7 +161,7 @@ alias termfix="TERM=rxvt-256color " #export TERM=rxvt-256color # Deli internet (iz wifi na eth) -alias share-internet="sudo iptables --table nat -A POSTROUTING --out-interface enp5s0 -j MASQUERADE && sudo iptables -A FORWARD --in-interface eth1 -j ACCEPT" +alias share-internet="sudo iptables --table nat -A POSTROUTING --out-interface enp5s0 -j MASQUERADE && sudo iptables -A FORWARD --in-interface enp5s0 -j ACCEPT" # Android studio in SDK export ANDROID_HOME="$HOME/Android/Sdk" @@ -176,8 +176,19 @@ export PATH=$PATH:/opt/gradle-8.7/bin # Cargo! export PATH=$HOME/.cargo/bin:$PATH +# CC = gcc +export CC=gcc + # Direnv eval "$(direnv hook zsh)" # Restart pipewire(debian) alias restart-pipewire-debian="systemctl restart --user wireplumber pipewire pipewire-pulse" + +function abeceda { + for x in {A..Z}; do; y=$(echo "$x" | tr '[:upper:]' '[:lower:]'); echo -e "\t$x\t$y"; done +} + +function ajpi { + IPV4=$(curl -s 'https://api.ipify.org?format=json' | jq '.ip') && HOME_IPV4='"193.77.221.150"' && if [ "$HOME_IPV4" = "$IPV4" ]; then; echo "LIO: $IPV4"; else; printf 'ipv4: %s\n' "$IPV4"; fi && printf 'ipv6: %s\n' $(curl -s 'https://api64.ipify.org?format=json' | jq '.ip') +} diff --git a/applications/emacs.desktop b/applications/emacsPW.desktop similarity index 85% rename from applications/emacs.desktop rename to applications/emacsPW.desktop index 86ac7be..b4ec4ec 100644 --- a/applications/emacs.desktop +++ b/applications/emacsPW.desktop @@ -1,10 +1,10 @@ [Desktop Entry] -Name=Emacs +Name=Emacs Pipewire GenericName=Text Editor Comment=Edit text MimeType=text/english;text/plain;text/x-makefile;text/x-c++hdr;text/x-c++src;text/x-chdr;text/x-csrc;text/x-java;text/x-moc;text/x-pascal;text/x-tcl;text/x-tex;application/x-shellscript;text/x-c;text/x-c++; # Run via pipewire (for supercollider!) -Exec=pw-jack emacs %F +Exec=env PIPEWIRE_LATENCY=128/48000 pw-jack emacs %F Icon=emacs Type=Application Terminal=false diff --git a/bin/png2ico b/bin/png2ico index 972ace1..abcaa7d 100755 --- a/bin/png2ico +++ b/bin/png2ico @@ -1,3 +1,3 @@ -#!/bin/bash +#!/usr/bin/env bash convert -background transparent "$1" -define icon:auto-resize=16,24,32,48,64,128,256 "$1.ico" diff --git a/guix/config.scm b/guix/config.scm index 9a555ec..7d45c32 100644 --- a/guix/config.scm +++ b/guix/config.scm @@ -1,15 +1,13 @@ (use-modules (gnu) (gnu system nss) - (gnu services base) - (gnu services pm) (nongnu packages linux) (nongnu system linux-initrd) (guix utils) (srfi srfi-1)) -(use-service-modules desktop xorg dns networking) -(use-package-modules bootloaders certs shells ssh version-control emacs vim wm freedesktop xorg fontutils) +(use-service-modules base desktop xorg dns networking docker pm cups) +(use-package-modules bootloaders certs shells ssh version-control emacs vim wm freedesktop xorg fontutils docker cups android) ;; Autologin (ker imamo encrypted root!) (define (auto-login-to-tty config tty user) @@ -21,6 +19,7 @@ (define %my-services (modify-services %desktop-services + ;; tty2 autologin (mingetty-service-type config => (auto-login-to-tty config "tty2" "g1smo")))) @@ -40,6 +39,10 @@ (initrd microcode-initrd) (firmware (list linux-firmware)) + (groups (cons* (user-group (name "adbusers")) + (user-group (name "plugdev")) + %base-groups)) + (users (cons* (user-account (name "g1smo") (comment "Yuri") @@ -48,41 +51,56 @@ (shell (file-append zsh "/bin/zsh")) (supplementary-groups '("wheel" "netdev" "audio" "video" - "dialout" "users" "lp")) + "dialout" "users" "lp" + ;; Za ddev + "docker" + ;; za fastboot/adb + "adbusers" + ;; networkmanager connections + "plugdev")) + (home-directory "/home/g1smo")) %base-user-accounts)) - (packages (append (list (specification->package "i3-wm") - (specification->package "i3status") - (specification->package "dmenu") - (specification->package "st") - ;; sistem - (specification->package "lvm2") - ;; WM zadeve - (specification->package "sway") - (specification->package "swaybg") - (specification->package "rofi") - (specification->package "i3-autotiling") - (specification->package "waybar") - (specification->package "gammastep") - (specification->package "foot") - (specification->package "eog") - (specification->package "nautilus") - ;; Urejevalniki teksta - (specification->package "emacs") - (specification->package "vim") - ;; Razno - (specification->package "zsh") - (specification->package "git") - (specification->package "file")) + (packages (append (list ;; Osnovni WM + (specification->package "i3-wm") + (specification->package "i3status") + (specification->package "dmenu") + (specification->package "st") + ;; sistem + (specification->package "lvm2") + (specification->pacakge "amdgpu-firmware") + ;; WM zadeve + (specification->package "sway") + (specification->package "swaybg") + (specification->package "rofi") + (specification->package "i3-autotiling") + (specification->package "waybar") + (specification->package "gammastep") + (specification->package "foot") + (specification->package "eog") + (specification->package "nautilus") + ;; Urejevalniki teksta + (specification->package "emacs") + (specification->package "vim") + ;; Razno + (specification->package "zsh") + (specification->package "git") + (specification->package "file") + ;; Napajanje, baterija ... + (specification->package "acpi") + (specification->package "file") + ;; Za docker (ddev) + (specification->package "docker")) %base-packages)) (services (cons* (service gnome-desktop-service-type) + ;; dns cache (service network-manager-service-type (network-manager-configuration - (dns "dnsmasq"))) + (dns "dnsmasq"))) (service pam-limits-service-type (list (pam-limits-entry "@audio" 'both 'rtprio 99) @@ -94,10 +112,21 @@ (ahci-runtime-pm-timeout 0))) (service thermald-service-type) (service bluetooth-service-type) + ;; Za ddev + (service docker-service-type) + (service containerd-service-type) + ;; printanje + (service cups-service-type + (cups-configuration + (web-interface? #t) + (extensions + (list cups-filters hplip-minimal)))) + ;; fastboot kot navadni user + (udev-rules-service 'android android-udev-rules) (remove - (lambda (service) - (eq? network-manager-service-type (service-kind service))) - %desktop-services))) + (lambda (service) + (eq? network-manager-service-type (service-kind service))) + %my-services ))) (swap-devices (list (swap-space @@ -110,7 +139,7 @@ (type luks-device-mapping)) (mapped-device (source "dbn-vg") - (targets (list "dbn--vg-guix" "dbn--vg-home")) + (targets (list "dbn--vg-guix" "dbn--vg-btr--home")) (type lvm-device-mapping)))) ;; Allow resolution of '.local' host names with mDNS. @@ -124,9 +153,10 @@ (options "subvol=@root,compress-force=zstd,space_cache=v2") (dependencies mapped-devices)) (file-system - (mount-point "/home") - (device "/dev/mapper/dbn--vg-home") - (type "ext4") + (mount-point "/mnt/debian-home") + (device "/dev/mapper/dbn--vg-btr--home") + (type "btrfs") + (options "compress-force=zstd,space_cache=v2") (dependencies mapped-devices)) (file-system (mount-point "/boot/efi") diff --git a/guix/home/firefox.scm b/guix/home/firefox.scm new file mode 100644 index 0000000..05807fc --- /dev/null +++ b/guix/home/firefox.scm @@ -0,0 +1,4 @@ +(specifications->packages + (list + "firefox-esr-wayland")) + diff --git a/guix/home/home-configuration-debian.scm b/guix/home/home-configuration-debian.scm new file mode 100644 index 0000000..3b7679c --- /dev/null +++ b/guix/home/home-configuration-debian.scm @@ -0,0 +1,289 @@ +;; This "home-environment" file can be passed to 'guix home reconfigure' +;; to reproduce the content of your profile. This is "symbolic": it only +;; specifies package names. To reproduce the exact same profile, you also +;; need to capture the channels being used, as returned by "guix describe". +;; See the "Replicating Guix" section in the manual. + +(use-modules (gnu home) + (gnu packages) + (gnu services) + (guix gexp) + (gnu home services) + (gnu home services shells) + (gnu home services pm) + (gnu home services desktop) + (gnu packages xdisorg) + (gnu home services sound)) + +(home-environment + ;; Below is the list of packages that will show up in your + ;; Home profile, under ~/.guix-home/profile. + (packages + (specifications->packages + (list + ;; E-pošta + "icedove-wayland" + ;"icedove-l10n:sl" + "mu" + "gnupg" + + ;; Chat + "element-desktop" + "irssi" + "signal-desktop" + + ;; Emacs in paketi + "emacs-next-pgtk-xwidgets" + "emacs-use-package" + "emacs-benchmark-init" + "emacs-general" + "emacs-evil" + "emacs-evil-collection" + "emacs-evil-org" + ;"emacs-treemacs-evil" + "emacs-vertico" + ;"emacs-savehist" + "emacs-marginalia" + "emacs-orderless" + ;"emacs-nerd-icons-completion" + "emacs-swiper" + "emacs-counsel" + "emacs-smex" + "emacs-helpful" + "emacs-which-key" + "emacs-crdt" + "emacs-openwith" + "emacs-org" + ;"emacs-ob-mermaid" + "emacs-visual-fill-column" + "emacs-writeroom" + "emacs-org-caldav" + "emacs-org-bullets" + "emacs-htmlize" + "emacs-gruvbox-theme" + "emacs-doom-modeline" + "emacs-nerd-icons" + "emacs-undo-tree" + "emacs-markdown-mode" + "emacs-guix" + "emacs-projectile" + "emacs-counsel-projectile" + "emacs-editorconfig" + "emacs-treemacs" + "emacs-smartparens" + "emacs-company" + "emacs-flycheck" + "emacs-format-all-the-code" + "emacs-direnv" + "emacs-magit" + ;"emacs-treesit-auto" + "emacs-rainbow-delimiters" + "emacs-geiser-guile" + "emacs-racket-mode" + "emacs-slime" + "emacs-web-mode" + "emacs-restclient" + ;"emacs-php-mode" + ;"emacs-drupal-mode" + ;"emacs-geben" + "emacs-js2-mode" + ;"emacs-vue-mode" + "emacs-rjsx-mode" + "emacs-pyvenv" + ;"emacs-sclang" + ;"emacs-fluxus-mode" + "emacs-extempore-mode" + ;"emacs-tidal" + "emacs-toml-mode" + "emacs-yaml-mode" + "emacs-arduino-mode" + "emacs-lsp-mode" + ;"emacs-mu4e" + ;"emacs-mu4e-marker-icons" + "emacs-mu4e-dashboard" + ;"emacs-mu4e-thread-folding" + "emacs-nyan-mode" + "emacs-svg-icon" + "emacs-scel" + "emacs-spinner" + "emacs-vertico" + "emacs-cider" + + ;; Splet + "librewolf" + "nyxt" + "surfraw" + + ;; Brskanje po fajlih + "thunar" + "ncdu" + + ;; Wine za wins programe + "wine64" + + ;; Guile programiranje + "guile-next" + "guile-goblins" + "guile-chickadee" + "guile-readline" + "guile-colorized" + "guile-dbi" + "guile-dbd-mysql" + "guile-dbd-sqlite3" + "guile-zstd" + "artanis" + "guile-studio" + "sicp" + + ;; Torrenti / fajl sharing + "transmission:gui" + "transmission" + "nicotine+" + + ;; Terminal, orodja + "foot" + "screen" + "reptyr" + "ripgrep" + "rsync" + "direnv" + "openssh" + "sshfs" + "woff-tools" + "gzip" + "unzip" + "pwgen" + "jq" + "curl" + "nextcloud-client" + "powertop" ; poraba energije + "ncurses" ; clear ukaz, najbrz tudi kaksni drugi + "hexyl" ; CLI hex editor + "gparted" + "xhost" ; za sudo gui (vidi zshrc) + + ;; upravljanje oken + "swayfx" + "swaybg" + "i3-wm" + "i3status" + "rofi-wayland" + "mako" + "gammastep" + "i3-autotiling" + "eog" ; gledanje slik + "vlc" ; multimedia plejer + "keepassxc" ; gesla / keyring + "seahorse" ; keyring urejevalnik + "glib:bin" ; za gsettings ukaz + "grim" ; zaslonske slike + "slurp" ; zaslonske slike + "pamixer" ; za jakost stimat + "brightnessctl" ; svetlost zaslona + "wdisplays" ; nastavitve zaslonov + + ;; pisave + "font-liberation" + "font-dejavu" + "font-fira-code" + "font-awesome" + + ;; zvok + "qpwgraph" + "qjackctl" + "pavucontrol" + "alsa-utils" + "non-mixer" + "audacity" + "ardour" + "infamous-plugins" + "swh-plugins-lv2" + "zam-plugins" + "x42-plugins" + "caps-plugins-lv2" + "zplugins" + ;"lsp-plugins" + "distrho-ports" + "omins-lv2" + "supercollider" + "soundconverter" + "picard" + "sooperlooper" + "ffmpeg" + + ;; mrezna orodja + "xl2tpd" + "nmap" + "wireshark" + "bind:utils" + ;; urejanje in branje dokumentov (ne-emacs) + "libreoffice" + "evince" + "calibre" + "gedit" + "okular" ;; Digitalno podpisovanje pdf dokumentov + + ;; Urejanje slik + "gimp" + "inkscape" + "gimp-resynthesizer" ; magicna orodja v gimpu + + ;; video urejanje + "kdenlive" + ;"olive" + + ;; Eye candy + "gnome-tweaks" + "arc-theme" + "numix-gtk-theme" + "qt5ct" + ;"hyprland" + ;"hyfetch" + "wfetch" + "texlive-etbb" + "bibata-cursor-theme" + "delft-icon-theme" + + ;; Programiranje + "rust" + "valgrind" + "xxd" + "make" + "python" + + ;; Igre + "gzdoom" + "gnubg" + "freegish" + "kigo" + "crawl-tiles" + + ;; Razno + "nss-certs" + "glibc-locales"))) + + ;; Below is the list of Home services. To search for available + ;; services, run 'guix home search KEYWORD' in a terminal. + (services + (list ;; Shell - zsh + (service home-zsh-service-type + (home-zsh-configuration + (zlogin (list (local-file "../../.zlogin" "zlogin"))) + (zshrc (list (local-file "../../.zshrc" "zshrc"))) + (zprofile (list (local-file "../../.zprofile" "zprofile"))))) + ;; Razne konfiguracije (~/.config) + (service home-files-service-type + ;; Desktop file overrides; pw-jack za supercolider + `((".local/share/applications/SuperColliderIDE.desktop" ,(local-file "../../applications/SuperColliderIDE.desktop")) + (".local/share/applications/emacsPW.desktop" ,(local-file "../../applications/emacsPW.desktop")))) + ;; Razni dotfajli - konfiguracije (~/.config) + (service home-xdg-configuration-files-service-type + `(("sway/config" ,(local-file "../../.config/sway/config")) + ("rofi/config.rasi" ,(local-file "../../.config/rofi/config.rasi")) + ("foot/foot.ini" ,(local-file "../../.config/foot/foot.ini")) + ("i3status/config" ,(local-file "../../.config/i3status/config")))) + ;; TODO povezi se druge dotfajle! + ;; Indikator prazne baterije + (service home-batsignal-service-type) + ;; Dbus storitev, ki se rabi kdaj + (service home-dbus-service-type)))) diff --git a/guix/home/home-configuration.scm b/guix/home/home-configuration.scm index 2d4ccc8..992d100 100644 --- a/guix/home/home-configuration.scm +++ b/guix/home/home-configuration.scm @@ -13,8 +13,7 @@ (gnu home services pm) (gnu home services desktop) (gnu packages xdisorg) - (gnu home services sound) - (small-guix home services gammastep)) + (gnu home services sound)) (home-environment ;; Below is the list of packages that will show up in your @@ -22,13 +21,19 @@ (packages (specifications->packages (list + ;; E-pošta + "icedove-wayland" + ;"icedove-l10n:sl" + "mu" + "gnupg" + ;; Chat "element-desktop" "irssi" "signal-desktop" ;; Emacs in paketi - "emacs-next-pgtk-xwidgets" + "emacs-next-pgtk" "emacs-use-package" "emacs-benchmark-init" "emacs-general" @@ -36,7 +41,7 @@ "emacs-evil-collection" "emacs-evil-org" ;"emacs-treemacs-evil" - "emacs-vertico" + ;"emacs-vertico" ;"emacs-savehist" "emacs-marginalia" "emacs-orderless" @@ -54,6 +59,7 @@ "emacs-writeroom" "emacs-org-caldav" "emacs-org-bullets" + "emacs-org-present" "emacs-htmlize" "emacs-gruvbox-theme" "emacs-doom-modeline" @@ -78,7 +84,7 @@ "emacs-slime" "emacs-web-mode" "emacs-restclient" - "emacs-php-mode" + ;"emacs-php-mode" ;"emacs-drupal-mode" ;"emacs-geben" "emacs-js2-mode" @@ -101,6 +107,8 @@ "emacs-svg-icon" "emacs-scel" "emacs-spinner" + "emacs-vertico" + "emacs-cider" ;; Splet "librewolf" @@ -120,13 +128,20 @@ "guile-goblins" "guile-chickadee" "guile-readline" + "guile-colorized" "guile-dbi" "guile-dbd-mysql" "guile-dbd-sqlite3" + "guile-zstd" "artanis" "guile-studio" "sicp" + ;; Drugi lispi + "racket" + "clojure" + "leiningen" + ;; Torrenti / fajl sharing "transmission:gui" "transmission" @@ -147,9 +162,19 @@ "pwgen" "jq" "curl" + "w3m" ; CLI spletni brskalnik "nextcloud-client" "powertop" ; poraba energije "ncurses" ; clear ukaz, najbrz tudi kaksni drugi + "hexyl" ; CLI hex editor + "gparted" + "xhost" ; za sudo gui (vidi zshrc) + "poppler" ; pdfimages, ... + "sox" ; zvočni urejevalnik v terminalu + + ;; C kompajlanje + "gcc-toolchain" + "bash" ;; upravljanje oken "swayfx" @@ -162,8 +187,9 @@ "mako" "libnotify" "gammastep" - "xdg-desktop-portal" + "xdg-desktop-portal-gtk" "xdg-desktop-portal-wlr" + "flatpak-xdg-utils" "i3-autotiling" "eog" ; gledanje slik "vlc" ; multimedia plejer @@ -178,10 +204,9 @@ ;; pisave "font-liberation" - "font-linuxlibertine" - "font-ghostscript" "font-dejavu" - "font-gnu-freefont" + "font-fira-code" + "font-awesome" ;; zvok "pipewire" @@ -198,10 +223,14 @@ "x42-plugins" "caps-plugins-lv2" "zplugins" - "lsp-plugins" + ;"lsp-plugins" "distrho-ports" "omins-lv2" - "supercollider:ide" + "supercollider" + "soundconverter" + "picard" + "sooperlooper" + "ffmpeg" ;; mrezna orodja "xl2tpd" @@ -217,14 +246,15 @@ "okular" ;; Digitalno podpisovanje pdf dokumentov ;; Urejanje slik - "gimp" + "gimp-next" "inkscape" "gimp-resynthesizer" ; magicna orodja v gimpu ;; video urejanje "kdenlive" - "pitivi" ;"olive" + "obs" + "obs-wlrobs" ;; Eye candy "gnome-tweaks" @@ -251,12 +281,7 @@ "gnubg" "freegish" "kigo" - - ;; E-pošta - "icedove-wayland" - "icedove-l10n:sl" - "mu" - "gnupg" + "crawl-tiles" ;; Razno "mesa" @@ -273,21 +298,30 @@ (zlogin (list (local-file "../../.zlogin" "zlogin"))) (zshrc (list (local-file "../../.zshrc" "zshrc"))) (zprofile (list (local-file "../../.zprofile" "zprofile"))))) - ;; Razni dotfajli - konfiguracije + ;; Razne konfiguracije (~/.config) + (service home-files-service-type + ;; Desktop file overrides; pw-jack za supercolider + `((".local/share/applications/SuperColliderIDE.desktop" ,(local-file "../../applications/SuperColliderIDE.desktop")) + (".local/share/applications/emacsPW.desktop" ,(local-file "../../applications/emacsPW.desktop")))) + ;; Razni dotfajli - konfiguracije (~/.config) (service home-xdg-configuration-files-service-type `(("sway/config" ,(local-file "../../.config/sway/config")) ("rofi/config.rasi" ,(local-file "../../.config/rofi/config.rasi")) ("foot/foot.ini" ,(local-file "../../.config/foot/foot.ini")) - ;; Desktop file overrides; pw-jack za supercolider - ("share/applications/SuperColliderIDE.desktop", "../../applications/SuperColliderIDE.desktop") - ("share/applications/emacs.desktop", "../../applications/emacs.desktop"))) + ("i3status/config" ,(local-file "../../.config/i3status/config")))) ;; TODO povezi se druge dotfajle! ;; Indikator prazne baterije - (service home-batsignal-service-type) + (service home-batsignal-service-type + (home-batsignal-configuration + (notifications-expire? #t))) ;; Rdecenje zaslona - (service gammastep-service-type - (gammastep-configuration - (coordinates "46.05108:14.50513"))) + (service home-redshift-service-type + (home-redshift-configuration + (redshift redshift-wayland) + (location-provider 'manual) + (adjustment-method 'wayland) + (latitude 46.05108) + (longitude 14.50513))) ;; Dbus storitev, ki se rabi kdaj (service home-dbus-service-type) ;; Pipewire sound daemon diff --git a/povezi.sh b/povezi.sh index b11f6cb..5132674 100755 --- a/povezi.sh +++ b/povezi.sh @@ -20,7 +20,8 @@ mkdir ~/.config/sway ln -s "$DIR/.config/sway/config" ~/.config/sway/config # i3status vrstica zgoraj -ln -s "$DIR/.i3status.conf" ~/.i3status.conf +mkdir ~/.config/i3status +ln -s "$DIR/.config/i3status/config" ~/.config/i3status/config # termite terminal (ok terminal za X) mkdir ~/.config/termite