diff --git a/.guix-channel/channel.scm b/.guix-channel/channel.scm new file mode 100644 index 0000000..e4d6d6a --- /dev/null +++ b/.guix-channel/channel.scm @@ -0,0 +1,9 @@ +(channel + (version 0) + (url "https://codeberg.org/glenneth/stash") + (name 'stash) + (introduction + (make-channel-introduction + "40-character-hex-string" ; We'll generate this + (openpgp-fingerprint + "40-character-hex-string")))) diff --git a/.guix-channel/stash/packages/stash.scm b/.guix-channel/stash/packages/stash.scm new file mode 100644 index 0000000..bfb6e0c --- /dev/null +++ b/.guix-channel/stash/packages/stash.scm @@ -0,0 +1,60 @@ +(define-module (stash packages stash) + #:use-module (guix packages) + #:use-module (guix git-download) + #:use-module (guix build-system gnu) + #:use-module ((guix licenses) #:prefix license:) + #:use-module (gnu packages guile)) + +(define-public stash + (package + (name "stash") + (version "0.1.0-alpha.1") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://codeberg.org/glenneth/stash.git") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0000000000000000000000000000000000000000000000000000")))) ; We'll generate this + (build-system gnu-build-system) + (arguments + `(#:phases + (modify-phases %standard-phases + (delete 'bootstrap) + (delete 'configure) + (replace 'build + (lambda _ + #t)) + (replace 'install + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (bin (string-append out "/bin")) + (site (string-append out "/share/guile/site/3.0")) + (go (string-append out "/lib/guile/3.0/site-ccache"))) + ;; Install binary + (install-file "stash.scm" bin) + (rename-file (string-append bin "/stash.scm") + (string-append bin "/stash")) + (chmod (string-append bin "/stash") #o755) + ;; Install modules + (for-each + (lambda (f) + (install-file f + (string-append site "/stash"))) + (find-files "modules/stash" "\\.scm$")) + #t))) + (delete 'check)))) ; No tests yet + (inputs + (list guile-3.0)) + (native-inputs + (list guile-3.0)) ; For compilation + (home-page "https://codeberg.org/glenneth/stash") + (synopsis "Symlink management utility") + (description + "Stash is a command-line utility written in Guile Scheme that helps organize +your files by moving them to a target location and creating symbolic links in +their original location. While it's great for managing dotfiles, it works with +any directories you want to organize.") + (license license:gpl3+))) diff --git a/channels.scm.example b/channels.scm.example new file mode 100644 index 0000000..51ad287 --- /dev/null +++ b/channels.scm.example @@ -0,0 +1,13 @@ +(list (channel + (name 'guix) + (url "https://git.savannah.gnu.org/git/guix.git") + (branch "master") + (introduction + (make-channel-introduction + "9edb3f66fd807b096b48283debdcddccfea34bad" + (openpgp-fingerprint + "BBB0 2DDF 2CEA F6A8 0D1D E643 A2A0 6DF2 A33A 54FA")))) + (channel + (name 'stash) + (url "https://codeberg.org/glenneth/stash") + (branch "main")))