1(define-module (nmeum packages desktop)2 #:use-module (guix)3 #:use-module (guix gexp)4 #:use-module (guix git-download)5 #:use-module (guix build-system gnu)6 #:use-module (guix build-system zig)7 #:use-module ((guix licenses) #:prefix license:)8 #:use-module (gnu packages)9 #:use-module (gnu packages audio)10 #:use-module (gnu packages fonts)11 #:use-module (gnu packages zig)12 #:use-module (gnu packages zig-xyz)13 #:use-module (gnu packages freedesktop)14 #:use-module (gnu packages linux)15 #:use-module (gnu packages xdisorg)16 #:use-module (gnu packages pkg-config)17 #:use-module (gnu packages fontutils)18 #:use-module (gnu packages textutils))1920(define-public creek21 (package22 (name "creek")23 (version "0.4.2")24 (source25 (origin26 (method git-fetch)27 (uri (git-reference28 (url "https://github.com/nmeum/creek")29 (commit (string-append "v" version))30 (recursive? #t)))31 (file-name (git-file-name name version))32 (sha25633 (base32 "0b1gpxgi207cqrls6qp0pd6749g60yfcrjii8nagm00c678bs3nx"))))34 (build-system zig-build-system)35 (arguments36 (list37 #:zig-release-type "safe"38 #:tests? #f))39 (native-inputs (list fcft40 pixman41 pkg-config42 zig-wayland43 zig-fcft44 zig-pixman))45 (home-page "https://github.com/nmeum/leeve")46 (synopsis47 "A minimalistic and malleable status bar for the River compositor.")48 (description "A fork of the creek status bar which intended to be49more mallable then the original version. For example,50supporting custom status bar information via stdin.")51 (license license:expat)))5253(define-public dam54 (let ((commit "e6eb713fb3239aad3c534502d8c0e42e4e514c8f")55 (revision "1"))56 (package57 (name "dam")58 (version (git-version "0" revision commit))59 (source60 (origin61 (method git-fetch)62 (uri (git-reference63 (url "https://codeberg.org/sewn/dam")64 (commit commit)))65 (file-name (git-file-name name version))66 (sha25667 (base32 "0ybhyvv3n1xdy5hb1xw7l2rzy73n5vhh8r60gfbf61crhggnzh8k"))))68 (build-system gnu-build-system)69 (arguments70 (list71 #:tests? #f72 #:make-flags #~(list (string-append "PREFIX=" #$output))73 #:phases #~(modify-phases %standard-phases74 (add-before 'configure 'set-cc-command75 (lambda _76 (setenv "CC" #$(cc-for-target))))77 (delete 'configure))))78 (inputs (list fcft pixman wayland wayland-protocols))79 (native-inputs (list pkg-config))80 (home-page "https://codeberg.org/sewn/dam")81 (synopsis "A itsy-bitsy dwm-esque bar for the river compositor")82 (description "")83 (license license:expat))))8485(define-public dumb-runtime-dir86 (package87 (name "dumb-runtime-dir")88 (version "1.0.4")89 (source90 (origin91 (method git-fetch)92 (uri (git-reference93 (url "https://github.com/ifreund/dumb_runtime_dir")94 (commit (string-append "v" version))))95 (file-name (git-file-name name version))96 (sha25697 (base32 "0nrxhvbh3bs4pi4f5h03zw1p1ys19qmmlx263ysly8302wkxk1m4"))))98 (build-system gnu-build-system)99 (arguments100 (list101 #:tests? #f102 #:make-flags #~(list (string-append "CC="103 #$(cc-for-target))104 (string-append "PREFIX=")105 (string-append "DESTDIR="106 #$output))107 #:phases #~(modify-phases %standard-phases108 (delete 'configure))))109 (inputs (list linux-pam))110 (native-inputs (list pkg-config))111 (home-page "https://github.com/ifreund/dumb_runtime_dir")112 (synopsis "Creates an XDG_RUNTIME_DIR via PAM")113 (description114 "Provides a acronym{PAM, Pluggable Authentication Module} for115creating a primitve @code{XDG_RUNTIME_DIR} that is never removed. This116is useful in conjuction with simple seat managers like @code{seatd}117which do not set @code{XDG_RUNTIME_DIR}.")118 (license license:bsd-0)))119120(define-public font-terminus-patched121 (package122 (inherit font-terminus)123 (name "font-terminus-patched")124 (arguments125 (substitute-keyword-arguments (package-arguments font-terminus)126 ((#:phases phases127 '%standard-phases)128 #~(modify-phases #$phases129 (add-after 'unpack 'patch-font130 (lambda _131 (invoke "patch" "-p0" "-i" "alt/td1.diff")132 (invoke "patch" "-p0" "-i" "alt/ll2.diff")))))))))133134(define-public ustatus135 (let ((commit "4032e2010de049472b7af57e85b7e4728fdde5e7")136 (revision "0"))137 (package138 (name "ustatus")139 (version (git-version "20190721" revision commit))140 (source141 (origin142 (method git-fetch)143 (uri (git-reference144 (url "https://github.com/nmeum/ustatus")145 (commit commit)))146 (file-name (git-file-name name version))147 (sha256148 (base32 "0a9pf51c2j68s7limdhw8ccqhyc1lk3q0iddfh1y65m18jh1vmn1"))))149 (build-system gnu-build-system)150 (arguments151 (list152 #:tests? #f153 #:make-flags154 #~(list (string-append "CC="155 #$(cc-for-target)))156 #:phases157 #~(modify-phases %standard-phases158 (replace 'configure159 (lambda _160 (with-output-to-file "config.h"161 (lambda _162 (display163 "static const int delay = 5;164 static const char *statsep = \" | \";165 static const char *timefmt = \"%a %d %b -- %H:%M:%S\";166 static const char *sysbat = \"/sys/class/power_supply/BAT0\";167 static const char *syscur = \"charge_now\";168 static const char *sysfull = \"charge_full_design\";169 static const unsigned int sndcrd = 0;170 static const char* swtchname = \"Master Playback Switch\";171 static const char* volumname = \"Master Playback Volume\";172173 static size_t batcapmay(char *dest, size_t n) {174 size_t ret;175 static int hasbat = -1;176177 if (hasbat == -1) {178 if (access(sysbat, F_OK)) {179 hasbat = 0;180 return 0;181 }182 hasbat = 1;183 } else if (!hasbat) {184 return 0;185 }186187 ret = batcap(dest, n);188 if (ret)189 ret += separator(&dest[ret], n - ret);190191 return ret;192 }193194 static size_t (* const sfuncs[])(char*, size_t) = {195 batcapmay,196 loadavg,197 separator,198 curtime,199 };200 ")))))201 (replace 'install202 (lambda* (#:key outputs #:allow-other-keys)203 (let* ((outdir (assoc-ref outputs "out"))204 (bindir (string-append outdir "/bin")))205 (mkdir-p bindir)206 (copy-file "ustatus"207 (string-append bindir "/ustatus"))))))))208 (inputs (list tinyalsa))209 (native-inputs (list pkg-config))210 (home-page "https://git.8pit.net/ustatus")211 (synopsis "Minimal status tool for dwm-like status bars")212 (description "")213 (license license:wtfpl2))))214215(define-public zig-fcft216 (package217 (name "zig-fcft")218 (version "1.1.0")219 (source220 (origin221 (method git-fetch)222 (uri (git-reference223 (url "https://git.sr.ht/~novakane/zig-fcft")224 (commit version)))225 (file-name (git-file-name name version))226 (sha256227 (base32 "0im0rdwww7xxvhmibfp3459h8wwdmihjb9m7vmzxkgqs4x77l114"))))228 (build-system zig-build-system)229 (arguments230 (list231 #:skip-build? #t232 #:tests? #f))233 (propagated-inputs (list zig-pixman fcft))234 (native-inputs (list pkg-config))235 (synopsis "Zig bindings for the fcft font library")236 (description "")237 (home-page "https://git.sr.ht/~novakane/zig-fcft")238 (license license:expat)))