guix-channel

A channel for the Guix package manager

git clone https://git.8pit.net/guix-channel.git

  1(define-module (nmeum packages desktop)
  2  #:use-module (nmeum packages)
  3  #:use-module (guix)
  4  #:use-module (guix gexp)
  5  #:use-module (guix git-download)
  6  #:use-module (guix build-system gnu)
  7  #:use-module (guix build-system trivial)
  8  #:use-module (guix build-system zig)
  9  #:use-module ((guix licenses) #:prefix license:)
 10  #:use-module (gnu packages)
 11  #:use-module (gnu packages audio)
 12  #:use-module (gnu packages bash)
 13  #:use-module (gnu packages fonts)
 14  #:use-module (gnu packages gawk)
 15  #:use-module (gnu packages zig)
 16  #:use-module (gnu packages zig-xyz)
 17  #:use-module (gnu packages freedesktop)
 18  #:use-module (gnu packages linux)
 19  #:use-module (gnu packages pkg-config)
 20  #:use-module (gnu packages fontutils)
 21  #:use-module (gnu packages textutils)
 22  #:use-module (gnu packages xdisorg))
 23
 24(define-public bemenu-emoji
 25  (package
 26    (name "bemenu-emoji")
 27    (version "16.0")
 28    (source #f)
 29    (build-system trivial-build-system)
 30    (arguments
 31      `(#:modules ((guix build utils))
 32        #:builder
 33        ,#~(begin
 34             (use-modules (guix build utils))
 35             (let* ((bindir (string-append #$output "/bin"))
 36                    (script (string-append bindir "/bemenu-emoji")))
 37               (mkdir-p bindir)
 38               (with-output-to-file script
 39                 (lambda _
 40                   (format #t
 41                     "#!~a
 42
 43emoji=$(~a -F '# ' '/fully-qualified/ { print $2 }' ~s | \\
 44 ~a -F 'E[0-9][0-9]*.[0-9][0-9]* ' '/E[0-9][0-9]*\\.[0-9][0-9]*/ { print $1 $2 }' | \\
 45 ~a -p emoji -l 15 \"$@\" | cut -d ' ' -f1)
 46
 47[ -n \"${emoji}\" ] || exit
 48exec ~a \"${emoji}\""
 49                     (search-input-file %build-inputs "/bin/sh")
 50                     (search-input-file %build-inputs (string-append "/bin/awk"))
 51                     (assoc-ref %build-inputs "unicode")
 52                     (search-input-file %build-inputs (string-append "/bin/awk"))
 53                     (search-input-file %build-inputs (string-append "/bin/bemenu"))
 54                     (search-input-file %build-inputs (string-append "/bin/wtype")))))
 55               (chmod script #o755)))))
 56    (inputs
 57      `(("bash-minimal" ,bash-minimal)
 58        ("bemenu" ,bemenu)
 59        ("gawk" ,gawk)
 60        ("wtype" ,wtype)
 61        ("unicode"
 62         ,(origin
 63            (method url-fetch)
 64            (uri (format #f "https://www.unicode.org/Public/emoji/~a/emoji-test.txt" version))
 65            (sha256
 66              (base32
 67                "15wn2f2yvk66576xs7lij8ip0gkawkqfhlv997i45wbcx0scbw14"))))))
 68    (synopsis "Provides a cc(1) symlink to gcc(1)")
 69    (description "")
 70    (home-page "https://github.com/nmeum/aports/blob/master/8pit/bemenu-emoji")
 71    (license license:public-domain)))
 72
 73(define-public creek
 74  (package
 75    (name "creek")
 76    (version "0.4.2")
 77    (source
 78     (origin
 79       (method git-fetch)
 80       (uri (git-reference
 81             (url "https://github.com/nmeum/creek")
 82             (commit (string-append "v" version))
 83             (recursive? #t)))
 84       (file-name (git-file-name name version))
 85       (sha256
 86        (base32 "0b1gpxgi207cqrls6qp0pd6749g60yfcrjii8nagm00c678bs3nx"))))
 87    (build-system zig-build-system)
 88    (arguments
 89     (list
 90      #:zig-release-type "safe"
 91      #:tests? #f))
 92    (native-inputs (list fcft
 93                         pixman
 94                         pkg-config
 95                         zig-wayland
 96                         zig-fcft
 97                         zig-pixman))
 98    (home-page "https://github.com/nmeum/leeve")
 99    (synopsis
100     "A minimalistic and malleable status bar for the River compositor.")
101    (description "A fork of the creek status bar which intended to be
102more mallable then the original version.  For example,
103supporting custom status bar information via stdin.")
104    (license license:expat)))
105
106(define-public dam
107  (let ((commit "e6eb713fb3239aad3c534502d8c0e42e4e514c8f")
108        (revision "1"))
109    (package
110      (name "dam")
111      (version (git-version "0" revision commit))
112      (source
113       (origin
114         (method git-fetch)
115         (uri (git-reference
116               (url "https://codeberg.org/sewn/dam")
117               (commit commit)))
118         (file-name (git-file-name name version))
119         (sha256
120          (base32 "0ybhyvv3n1xdy5hb1xw7l2rzy73n5vhh8r60gfbf61crhggnzh8k"))))
121      (build-system gnu-build-system)
122      (arguments
123       (list
124        #:tests? #f
125        #:make-flags #~(list (string-append "PREFIX=" #$output))
126        #:phases #~(modify-phases %standard-phases
127                     (add-before 'configure 'set-cc-command
128                       (lambda _
129                         (setenv "CC" #$(cc-for-target))))
130                     (delete 'configure))))
131      (inputs (list fcft pixman wayland wayland-protocols))
132      (native-inputs (list pkg-config))
133      (home-page "https://codeberg.org/sewn/dam")
134      (synopsis "A itsy-bitsy dwm-esque bar for the river compositor")
135      (description "")
136      (license license:expat))))
137
138(define-public dumb-runtime-dir
139  (package
140    (name "dumb-runtime-dir")
141    (version "1.0.4")
142    (source
143     (origin
144       (method git-fetch)
145       (uri (git-reference
146             (url "https://github.com/ifreund/dumb_runtime_dir")
147             (commit (string-append "v" version))))
148       (file-name (git-file-name name version))
149       (sha256
150        (base32 "0nrxhvbh3bs4pi4f5h03zw1p1ys19qmmlx263ysly8302wkxk1m4"))))
151    (build-system gnu-build-system)
152    (arguments
153     (list
154      #:tests? #f
155      #:make-flags #~(list (string-append "CC="
156                                          #$(cc-for-target))
157                           (string-append "PREFIX=")
158                           (string-append "DESTDIR="
159                                          #$output))
160      #:phases #~(modify-phases %standard-phases
161                   (delete 'configure))))
162    (inputs (list linux-pam))
163    (native-inputs (list pkg-config))
164    (home-page "https://github.com/ifreund/dumb_runtime_dir")
165    (synopsis "Creates an XDG_RUNTIME_DIR via PAM")
166    (description
167     "Provides a acronym{PAM, Pluggable Authentication Module} for
168creating a primitve @code{XDG_RUNTIME_DIR} that is never removed.  This
169is useful in conjuction with simple seat managers like @code{seatd}
170which do not set @code{XDG_RUNTIME_DIR}.")
171    (license license:bsd-0)))
172
173(define-public font-terminus-patched
174  (package
175    (inherit font-terminus)
176    (name "font-terminus-patched")
177    (arguments
178     (substitute-keyword-arguments (package-arguments font-terminus)
179       ((#:phases phases
180         '%standard-phases)
181        #~(modify-phases #$phases
182            (add-after 'unpack 'patch-font
183              (lambda _
184                (invoke "patch" "-p0" "-i" "alt/td1.diff")
185                (invoke "patch" "-p0" "-i" "alt/ll2.diff")))))))))
186
187(define-public ustatus
188  (let ((commit "4032e2010de049472b7af57e85b7e4728fdde5e7")
189        (revision "0"))
190    (package
191      (name "ustatus")
192      (version (git-version "20190721" revision commit))
193      (source
194       (origin
195         (method git-fetch)
196         (uri (git-reference
197               (url "https://github.com/nmeum/ustatus")
198               (commit commit)))
199         (file-name (git-file-name name version))
200         (sha256
201          (base32 "0a9pf51c2j68s7limdhw8ccqhyc1lk3q0iddfh1y65m18jh1vmn1"))))
202      (build-system gnu-build-system)
203      (arguments
204       (list
205        #:tests? #f
206        #:make-flags
207        #~(list (string-append "CC="
208                               #$(cc-for-target)))
209        #:phases
210        #~(modify-phases %standard-phases
211            (replace 'configure
212              (lambda _
213                (symlink #$(nmeum-file "ustatus-config.h") "config.h")))
214            (replace 'install
215              (lambda* (#:key outputs #:allow-other-keys)
216                (let* ((outdir (assoc-ref outputs "out"))
217                       (bindir (string-append outdir "/bin")))
218                  (mkdir-p bindir)
219                  (copy-file "ustatus"
220                             (string-append bindir "/ustatus"))))))))
221      (inputs (list tinyalsa))
222      (native-inputs (list pkg-config))
223      (home-page "https://git.8pit.net/ustatus")
224      (synopsis "Minimal status tool for dwm-like status bars")
225      (description "")
226      (license license:wtfpl2))))
227
228(define-public zig-fcft
229  (package
230    (name "zig-fcft")
231    (version "1.1.0")
232    (source
233     (origin
234       (method git-fetch)
235       (uri (git-reference
236             (url "https://git.sr.ht/~novakane/zig-fcft")
237             (commit version)))
238       (file-name (git-file-name name version))
239       (sha256
240        (base32 "0im0rdwww7xxvhmibfp3459h8wwdmihjb9m7vmzxkgqs4x77l114"))))
241    (build-system zig-build-system)
242    (arguments
243     (list
244      #:skip-build? #t
245      #:tests? #f))
246    (propagated-inputs (list zig-pixman fcft))
247    (native-inputs (list pkg-config))
248    (synopsis "Zig bindings for the fcft font library")
249    (description "")
250    (home-page "https://git.sr.ht/~novakane/zig-fcft")
251    (license license:expat)))