| 1 | |
| 2 | |
| 3 | |
| 4 | |
| 5 | |
| 6 | |
| 7 | |
| 8 | |
| 9 | |
| 10 | |
| 11 | |
| 12 | |
| 13 | |
| 14 | |
| 15 | |
| 16 | |
| 17 | |
| 18 | |
| 19 | |
| 20 | |
| 21 | |
| 22 | |
| 23 | |
| 24 |
|
| 25 | (define-module (gnu packages task-runners)
|
| 26 | #:use-module (gnu packages bash)
|
| 27 | #:use-module (gnu packages compression)
|
| 28 | #:use-module (gnu packages golang-xyz)
|
| 29 | #:use-module (gnu packages mail)
|
| 30 | #:use-module (gnu packages scheme)
|
| 31 | #:use-module (guix build-system copy)
|
| 32 | #:use-module (guix build-system gnu)
|
| 33 | #:use-module (guix build-system go)
|
| 34 | #:use-module (guix download)
|
| 35 | #:use-module (guix gexp)
|
| 36 | #:use-module (guix git-download)
|
| 37 | #:use-module ((guix licenses) #:prefix license:)
|
| 38 | #:use-module (guix packages)
|
| 39 | #:use-module (guix utils))
|
| 40 |
|
| 41 | (define-public faber
|
| 42 | (package
|
| 43 | (name "faber")
|
| 44 | (version "0.1.1")
|
| 45 | (source
|
| 46 | (origin
|
| 47 | (method git-fetch)
|
| 48 | (uri (git-reference
|
| 49 | (url "https://github.com/Junker/faber")
|
| 50 | (commit version)))
|
| 51 | (file-name (git-file-name name version))
|
| 52 | (sha256
|
| 53 | (base32 "17xjg92vwg7n06lx4xbsnd7wvsgqcw8h10ha5365rsfs49bd3cyf"))))
|
| 54 | (inputs (list gauche))
|
| 55 | (build-system copy-build-system)
|
| 56 | (arguments
|
| 57 | '(#:install-plan '(("faber" "bin/"))))
|
| 58 | (synopsis "Task runner with power of Scheme")
|
| 59 | (description "Faber is a CLI task runner designed to leverage the power and
|
| 60 | flexibility of Gauche Scheme.
|
| 61 | Unlike other build systems that rely on custom formats, Faber uses Gauche
|
| 62 | Scheme, allowing you to write build scripts using familiar Scheme syntax.")
|
| 63 | (home-page "https://github.com/Junker/faber")
|
| 64 | (license license:expat)))
|
| 65 |
|
| 66 | (define-public run
|
| 67 | (package
|
| 68 | (name "run")
|
| 69 | (version "0.11.2")
|
| 70 | (source
|
| 71 | (origin
|
| 72 | (method git-fetch)
|
| 73 | (uri (git-reference
|
| 74 | (url "https://github.com/TekWizely/run")
|
| 75 | (commit (string-append "v" version))))
|
| 76 | (file-name (git-file-name name version))
|
| 77 | (sha256
|
| 78 | (base32 "1p9hyc3zrjh58nqdc2j2qnkcyg7z8av2q7fb49ycs4292awl0zka"))))
|
| 79 | (build-system go-build-system)
|
| 80 | (arguments
|
| 81 | (list
|
| 82 | #:install-source? #f
|
| 83 | #:import-path "github.com/tekwizely/run"))
|
| 84 | (native-inputs
|
| 85 | (list go-github-com-goreleaser-fileglob
|
| 86 | go-github-com-subosito-gotenv
|
| 87 | go-github-com-tekwizely-go-parsing))
|
| 88 | (home-page "https://github.com/TekWizely/run")
|
| 89 | (synopsis "Easily manage and invoke small scripts and wrappers")
|
| 90 | (description
|
| 91 | "Run is a tool to easily manage and invoke small scripts and wrappers by
|
| 92 | using a Runfile.")
|
| 93 | (license license:expat)))
|
| 94 |
|
| 95 | (define-public task-spooler
|
| 96 | (package
|
| 97 | (name "task-spooler")
|
| 98 | (version "1.0.3")
|
| 99 | (source
|
| 100 | (origin
|
| 101 | (method url-fetch)
|
| 102 | (uri (string-append "https://viric.name/soft/ts/ts-"
|
| 103 | version ".tar.gz"))
|
| 104 | (sha256
|
| 105 | (base32 "0a5l8bjq869lvqys3amsil933vmm9b387axp1jv3bi9xah8k70zs"))))
|
| 106 | (build-system gnu-build-system)
|
| 107 | (arguments
|
| 108 | (list
|
| 109 | #:make-flags
|
| 110 | #~(let ((c-flags "-g -O2"))
|
| 111 | (list (string-append "PREFIX=" #$output)
|
| 112 | (string-append "CC=" #$(cc-for-target))
|
| 113 | (string-append "CFLAGS=" c-flags)))
|
| 114 | #:phases
|
| 115 | #~(modify-phases %standard-phases
|
| 116 | (delete 'configure) |
| 117 | (add-after 'unpack 'rename-and-patch-paths
|
| 118 | (lambda* (#:key inputs #:allow-other-keys)
|
| 119 | |
| 120 | |
| 121 | (rename-file "ts.1" "tsp.1") |
| 122 | (substitute* '("Makefile" "testbench.sh")
|
| 123 | (("\\bts\\b") "tsp"))
|
| 124 | |
| 125 | (substitute* '("execute.c" "list.c")
|
| 126 | (("execlp\\(\"gzip\"")
|
| 127 | (format #f "execlp(\"~a/bin/gzip\""
|
| 128 | #$(this-package-input "gzip")))
|
| 129 | (("execlp\\(\"sh\"")
|
| 130 | (format #f "execlp(\"~a/bin/sh\""
|
| 131 | #$(this-package-input "bash-minimal")))
|
| 132 | (("/bin/sh\\b")
|
| 133 | (format #f "~a/bin/sh"
|
| 134 | #$(this-package-input "bash-minimal"))))
|
| 135 | (substitute* "mail.c"
|
| 136 | (("/usr/sbin/sendmail")
|
| 137 | (format #f "~a/sbin/sendmail"
|
| 138 | #$(this-package-input "sendmail"))))))
|
| 139 | (replace 'check
|
| 140 | (lambda* (#:key tests? #:allow-other-keys)
|
| 141 | (if tests?
|
| 142 | (begin
|
| 143 | (setenv "PATH"
|
| 144 | (string-append (getenv "PATH") ":" (getcwd)))
|
| 145 | (invoke "./testbench.sh"))
|
| 146 | (format #t "test suite not run ~%")))))))
|
| 147 | (inputs
|
| 148 | (list bash-minimal gzip sendmail))
|
| 149 | (home-page "https://viric.name/soft/ts/")
|
| 150 | (synopsis "UNIX task queue system")
|
| 151 | (description
|
| 152 | "Task spooler lets users run shell commands asynchronously one after the
|
| 153 | other in a separate process.")
|
| 154 | (license license:gpl2+)))
|
| 155 |
|
| 156 | (define-public xc
|
| 157 | (package
|
| 158 | (name "xc")
|
| 159 | (version "0.9.0")
|
| 160 | (source
|
| 161 | (origin
|
| 162 | (method git-fetch)
|
| 163 | (uri (git-reference
|
| 164 | (url "https://github.com/joerdav/xc")
|
| 165 | (commit (string-append "v" version))))
|
| 166 | (file-name (git-file-name name version))
|
| 167 | (sha256
|
| 168 | (base32 "0m8r2mf98f6b6pzjaadg46y5j96byif4ybn5aczlzg7v64yi3v44"))))
|
| 169 | (build-system go-build-system)
|
| 170 | (arguments
|
| 171 | (list
|
| 172 | #:install-source? #f
|
| 173 | #:import-path "github.com/joerdav/xc/cmd/xc"
|
| 174 | #:unpack-path "github.com/joerdav/xc"
|
| 175 | #:test-subdirs #~(list "../../...")))
|
| 176 | (native-inputs
|
| 177 | (list go-github-com-charmbracelet-bubbles
|
| 178 | go-github-com-charmbracelet-bubbletea
|
| 179 | go-github-com-charmbracelet-lipgloss
|
| 180 | go-github-com-google-shlex
|
| 181 | go-github-com-posener-complete-v2
|
| 182 | go-mvdan-cc-sh-v3))
|
| 183 | (home-page "https://xcfile.dev/")
|
| 184 | (synopsis "Documentation-oriented task runner")
|
| 185 | (description
|
| 186 | "@code{xc} is a task runner inspired by @code{Make} and @code{npm run}
|
| 187 | that aims to be discoverable and approachable by fully integrating with
|
| 188 | project documentation.")
|
| 189 | (license license:expat)))
|