From patchwork Sat Sep 18 14:10:22 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: phodina X-Patchwork-Id: 33123 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 76EA727BBE3; Sat, 18 Sep 2021 15:13:07 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, FREEMAIL_FROM,MAILING_LIST_MULTI,RCVD_IN_MSPIKE_H2,SPF_HELO_PASS, T_DKIM_INVALID,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.2 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id E9EF527BBE1 for ; Sat, 18 Sep 2021 15:13:06 +0100 (BST) Received: from localhost ([::1]:60018 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mRb5V-0004jI-Vb for patchwork@mira.cbaines.net; Sat, 18 Sep 2021 10:13:06 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:50530) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mRb3W-0003NX-S3 for guix-patches@gnu.org; Sat, 18 Sep 2021 10:11:04 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:53040) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mRb3W-0008Er-HJ for guix-patches@gnu.org; Sat, 18 Sep 2021 10:11:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mRb3W-000337-D4 for guix-patches@gnu.org; Sat, 18 Sep 2021 10:11:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#49942] [PATCH v2] gnu: Add shell-color-scripts. References: In-Reply-To: Resent-From: phodina Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sat, 18 Sep 2021 14:11:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 49942 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Maxime Devos Cc: 49942@debbugs.gnu.org Received: via spool by 49942-submit@debbugs.gnu.org id=B49942.163197423911691 (code B ref 49942); Sat, 18 Sep 2021 14:11:02 +0000 Received: (at 49942) by debbugs.gnu.org; 18 Sep 2021 14:10:39 +0000 Received: from localhost ([127.0.0.1]:36353 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mRb35-00032R-AZ for submit@debbugs.gnu.org; Sat, 18 Sep 2021 10:10:39 -0400 Received: from mail-4322.protonmail.ch ([185.70.43.22]:27619) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mRb31-000327-Em for 49942@debbugs.gnu.org; Sat, 18 Sep 2021 10:10:33 -0400 Date: Sat, 18 Sep 2021 14:10:22 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail; t=1631974224; bh=/jWvDv3ZNZQBGv/1vl+ygibVyUUyEYvpUSCc+mzOvrw=; h=Date:To:From:Cc:Reply-To:Subject:From; b=BQxqHtwReK/gYHdwXL9Z9tJbL/ktn6NTr+bGF6xmi1t5YdlaoJgfD9JiDc6Q0pR8n 98nnVEJyW6X4Ra+gt/5nClXkgcWyz8EuHwsk5AHtlI5NFzKJhdZMHEoOkg6+YurCbs untfy0vYfMufOce49uIfQ5Nc070j+mADNq5wqyIE= Message-ID: <8r1GXqISfNJpN9TzGPo7yBAkgpq6gthRXhZYLjQkU-kWQkNvdsDZ-uXem9rTlugAAVzJLZ9zzmeaBioQzUdY8GSN1o3Tu3pwlofd6ccxTD4=@protonmail.com> MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" Reply-to: phodina X-ACL-Warn: , phodina via Guix-patches X-Patchwork-Original-From: phodina via Guix-patches via From: phodina X-getmail-retrieved-from-mailbox: Patches Hi Maxime, thanks for hints on improvements! --8<---------------cut here---------------start------------->8-- * gnu/packages/terminals.scm (shell-color-scripts): New variable. --- 2.32.0 diff --git a/gnu/packages/terminals.scm b/gnu/packages/terminals.scm index de9bec9e66..d7e3199606 100644 --- a/gnu/packages/terminals.scm +++ b/gnu/packages/terminals.scm @@ -27,6 +27,7 @@ ;;; Copyright © 2021 Raphaël Mélotte ;;; Copyright © 2021 ikasero ;;; Copyright © 2021 Brice Waegeneire +;;; Copyright © 2021 Petr Hodina ;;; ;;; This file is part of GNU Guix. ;;; @@ -47,6 +48,7 @@ #:use-module ((guix licenses) #:prefix license:) #:use-module (guix build-system cargo) #:use-module (guix build-system cmake) + #:use-module (guix build-system copy) #:use-module (guix build-system gnu) #:use-module (guix build-system glib-or-gtk) #:use-module (guix build-system go) @@ -58,6 +60,7 @@ #:use-module (guix utils) #:use-module (gnu packages) #:use-module (gnu packages autotools) + #:use-module (gnu packages base) #:use-module (gnu packages build-tools) ;for meson-0.55 #:use-module (gnu packages check) #:use-module (gnu packages cmake) @@ -69,6 +72,7 @@ #:use-module (gnu packages fontutils) #:use-module (gnu packages freedesktop) #:use-module (gnu packages fribidi) + #:use-module (gnu packages gawk) #:use-module (gnu packages gettext) #:use-module (gnu packages ghostscript) #:use-module (gnu packages gl) @@ -810,6 +814,57 @@ It's a terminal emulator with few dependencies, so you don't need a full GNOME desktop installed to have a decent terminal emulator.") (license license:gpl2))) +(define-public shell-color-scripts + (let ((commit "3dbdfac24bb629238fdc3e1c8909e2c8577f8735") + (revision "1")) + (package + (name "colorscript") + (version commit) + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://gitlab.com/dwt1/shell-color-scripts") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0lkiz6fkrqryr1vh0lh067q7hp8ba8887pkk8caipqphjswp2z16")))) + (build-system copy-build-system) + (arguments + `(#:install-plan '(("colorscript.sh" "bin/colorscript.sh") + ("colorscripts" "colorscripts")) + #:phases + (modify-phases %standard-phases + (add-after 'unpack 'fix-colorscipts-location + (lambda* (#:key outputs #:allow-other-keys) + (substitute* "colorscript.sh" + (("/opt/shell-color-scripts/colorscripts") + (string-append (assoc-ref outputs "out") "/colorscripts")) + (("sed") (string-append + (assoc-ref %build-inputs "sed") "/bin/sed")) + (("awk") (string-append + (assoc-ref %build-inputs "gawk") "/bin/awk")) + (("wc") (string-append + (assoc-ref %build-inputs "coreutils") "/bin/wc")) + (("nl") (string-append + (assoc-ref %build-inputs "coreutils") "/bin/nl")) + (("cut") (string-append + (assoc-ref %build-inputs "coreutils") "/bin/cut")) + (("echo") (string-append + (assoc-ref %build-inputs "coreutils") "/bin/echo")) + (("printf") (string-append + (assoc-ref %build-inputs "coreutils") "/bin/printf")) + (("tr") (string-append + (assoc-ref %build-inputs "coreutils") "/bin/tr")))))))) + (inputs `(("ncurses" ,ncurses) + ("gawk" ,gawk) + ("sed" ,sed) + ("coreutils" ,coreutils))) + (synopsis "Collection of terminal color scripts") + (description "Collection of terminal color scripts") + (home-page "https://gitlab.com/dwt1/shell-color-scripts") + (license license:expat)))) + (define-public go-github.com-nsf-termbox-go (let ((commit "288510b9734e30e7966ec2f22b87c5f8e67345e3") (revision "1"))