Initializing the channel with module sjw

This commit is contained in:
Tissevert 2022-10-29 17:25:53 +02:00
commit 48d843c54b
2 changed files with 136 additions and 0 deletions

46
README.md Normal file
View File

@ -0,0 +1,46 @@
# The loom
Here is a channel for my [guix](https://guix.gnu.org/) packages. Everything is
free software and candidate for an eventual release in the official channel but
this repository is meant as a convenient upstream for fast publication (and
hence can not be expected to be as stable as the official channel).
## How to use
### The proper way
The following snippet declares this channel for `guix` (mind the `branch` field):
```guile
(channel
(name 'loom)
(url "https://git.marvid.fr/Tissevert/loom.git")
(branch "main"))
```
Following the [official
instructions](https://guix.gnu.org/fr/manual/devel/en/html_node/Specifying-Additional-Channels.html),
add it to your `channels.scm` (which should be located at
`~/.config/guix/channels.scm`, create it if it doesn't exist). If this is your
first additional channel, your new `channels.scm` should look like this:
```guile
(cons* (channel
(name 'loom)
(url "https://git.marvid.fr/Tissevert/loom.git")
(branch "main"))
%default-channels)
```
Then just `guix pull` and my packages should pop up in a search.
### Quick'n'dirty
If you just want to try a package without modifying your local `guix`
configuration, just download this repository and use the `--load-path` (short
`-L`) option with the path to your local copy as argument. For instance, from
within the copy, this should return results:
```
$ guix search -L . sjw
```

90
loom/packages/sjw.scm Normal file
View File

@ -0,0 +1,90 @@
(define-module (loom packages sjw)
#:use-module ((gnu packages haskell-xyz)
#:select (ghc-attoparsec ghc-random ghc-optparse-applicative))
#:use-module ((guix build-system copy)
#:select (copy-build-system))
#:use-module ((guix build-system haskell)
#:select (haskell-build-system))
#:use-module ((guix git-download)
#:select (git-fetch git-file-name git-reference))
#:use-module ((guix licenses)
#:select (gpl3+))
#:use-module ((guix packages)
#:select (base32 origin package search-path-specification)))
(define-public sjw
(package
(name "sjw")
(version "0.1.3.0")
(source (origin
(method git-fetch)
(uri (git-reference
(url "https://git.marvid.fr/Tissevert/SJW")
(commit (string-append "v" version))))
(file-name (git-file-name name version))
(sha256
(base32
"1jhwsxhqmsifrafqbil1yj3d83sjb8fliwbhayc1wb904ih99k45"))))
(build-system haskell-build-system)
(inputs (list ghc-attoparsec ghc-random ghc-optparse-applicative))
(native-search-paths
(list (search-path-specification
(variable "SJW_PATH")
(files '("lib/SJW")))))
(home-page "https://git.marvid.fr/Tissevert/SJW")
(synopsis "The Simple Javascript Wrench")
(description
"SJW is a very simple tool to pack several JS modules into a single
script. It doesn't really do proper compilation work (yet) except
resolving the modules dependencies and detecting import loops but it
provides each module with an independent execution context in the
resulting script.")
(license gpl3+)))
(define-public sjw-unitjs
(package
(name "sjw-unitjs")
(version "0.1.2")
(source (origin
(method git-fetch)
(uri (git-reference
(url "https://git.marvid.fr/Tissevert/UnitJS")
(commit (string-append "v" version))))
(file-name (git-file-name name version))
(sha256
(base32
"1g6f5zny2zhwfysijws621552b6sm6jm3fr254bczsxlpibnxygm"))))
(build-system copy-build-system)
(arguments
'(#:install-plan '(("src" "lib/SJW/unitJS"))))
(home-page "https://git.marvid.fr/Tissevert/UnitJS")
(synopsis "The Simple Javascript Wrench.")
(description
"A collection of JS modules to write simple web applications. It covers
the basics, providing asynchronous operations without any need for
promises-support from the browser as well as primitives to create DOM
elements and basic functional-programming tooling.")
(license gpl3+)))
(define-public sjw-wtk
(package
(name "sjw-wtk")
(version "0.1.0")
(source (origin
(method git-fetch)
(uri (git-reference
(url "https://git.marvid.fr/Tissevert/WTK")
(commit (string-append "v" version))))
(file-name (git-file-name name version))
(sha256
(base32
"0d51j2dcr4p0bpy963zzyj0711314xcadkrrg1vb0y78xs3gdqvy"))))
(build-system copy-build-system)
(arguments
'(#:install-plan '(("src" "lib/SJW/WTK"))))
(home-page "https://git.marvid.fr/Tissevert/WTK")
(synopsis "The Web Tool Kit")
(description
"The Web Tool Kit aims at providing high-level abstraction modules to
build web applications easily.")
(license gpl3+)))