mirror of
https://git.in.rschanz.org/ryan77627/guix.git
synced 2024-11-07 23:46:13 -05:00
gnu: Add nerd-dictation/wayland.
* gnu/packages/machine-learning.scm (nerd-dictation/wayland): New variable. Signed-off-by: Ludovic Courtès <ludo@gnu.org>
This commit is contained in:
parent
eecb288ca2
commit
d5b54e0137
1 changed files with 35 additions and 0 deletions
|
@ -45,6 +45,7 @@ (define-module (gnu packages machine-learning)
|
||||||
#:use-module (guix build-system ocaml)
|
#:use-module (guix build-system ocaml)
|
||||||
#:use-module (guix build-system python)
|
#:use-module (guix build-system python)
|
||||||
#:use-module (guix build-system r)
|
#:use-module (guix build-system r)
|
||||||
|
#:use-module (guix build-system trivial)
|
||||||
#:use-module (guix git-download)
|
#:use-module (guix git-download)
|
||||||
#:use-module (gnu packages)
|
#:use-module (gnu packages)
|
||||||
#:use-module (gnu packages adns)
|
#:use-module (gnu packages adns)
|
||||||
|
@ -103,6 +104,7 @@ (define-module (gnu packages machine-learning)
|
||||||
#:use-module (gnu packages video)
|
#:use-module (gnu packages video)
|
||||||
#:use-module (gnu packages web)
|
#:use-module (gnu packages web)
|
||||||
#:use-module (gnu packages xml)
|
#:use-module (gnu packages xml)
|
||||||
|
#:use-module (gnu packages xdisorg)
|
||||||
#:use-module (gnu packages xorg)
|
#:use-module (gnu packages xorg)
|
||||||
#:use-module (ice-9 match))
|
#:use-module (ice-9 match))
|
||||||
|
|
||||||
|
@ -3636,3 +3638,36 @@ (define-public nerd-dictation
|
||||||
there are no background processes. Dictation is accessed manually with
|
there are no background processes. Dictation is accessed manually with
|
||||||
@code{nerd-dictation begin} and @code{nerd-dictation end} commands.")
|
@code{nerd-dictation begin} and @code{nerd-dictation end} commands.")
|
||||||
(license license:gpl3+))))
|
(license license:gpl3+))))
|
||||||
|
|
||||||
|
(define-public nerd-dictation/wayland
|
||||||
|
(package
|
||||||
|
(inherit nerd-dictation)
|
||||||
|
(name "nerd-dictation-wayland")
|
||||||
|
(inputs (list bash-minimal nerd-dictation))
|
||||||
|
(propagated-inputs (list ydotool sox))
|
||||||
|
(build-system trivial-build-system)
|
||||||
|
(arguments
|
||||||
|
(list
|
||||||
|
#:modules '((guix build utils))
|
||||||
|
#:builder
|
||||||
|
#~(begin
|
||||||
|
(use-modules (guix build utils))
|
||||||
|
(let* ((exe (string-append #$output "/bin/nerd-dictation"))
|
||||||
|
(original-exe #$(file-append nerd-dictation
|
||||||
|
"/bin/nerd-dictation"))
|
||||||
|
(bash #$(this-package-input "bash-minimal"))
|
||||||
|
(bash-exe (string-append bash "/bin/bash")))
|
||||||
|
(mkdir-p (dirname exe))
|
||||||
|
(call-with-output-file exe
|
||||||
|
(lambda (port)
|
||||||
|
(format port "#!~a
|
||||||
|
if [ \"$1\" = begin ]
|
||||||
|
then
|
||||||
|
exec ~a $@ --input=SOX --simulate-input-tool=YDOTOOL
|
||||||
|
else
|
||||||
|
exec ~a $@
|
||||||
|
fi"
|
||||||
|
bash-exe
|
||||||
|
original-exe
|
||||||
|
original-exe)))
|
||||||
|
(chmod exe #o555)))))))
|
||||||
|
|
Loading…
Reference in a new issue