From patchwork Fri Jun 21 19:01:08 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Igor Goryachev X-Patchwork-Id: 65555 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 787F927BBE2; Fri, 21 Jun 2024 20:02:18 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id B88BE27BBE9 for ; Fri, 21 Jun 2024 20:02:16 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sKjWV-0003ib-Sx; Fri, 21 Jun 2024 15:02:11 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sKjWN-0003hj-Bh for guix-patches@gnu.org; Fri, 21 Jun 2024 15:02:03 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1sKjWN-0007Ef-1N for guix-patches@gnu.org; Fri, 21 Jun 2024 15:02:03 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1sKjWM-00056X-1d for guix-patches@gnu.org; Fri, 21 Jun 2024 15:02:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#71707] [PATCH 02/15] gnu: elixir-hex: Remove redundant directory, fix lint warnings. Resent-From: Igor Goryachev Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Fri, 21 Jun 2024 19:02:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 71707 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 71707@debbugs.gnu.org Cc: Igor Goryachev , Andrew Tropin Received: via spool by 71707-submit@debbugs.gnu.org id=B71707.171899651519540 (code B ref 71707); Fri, 21 Jun 2024 19:02:02 +0000 Received: (at 71707) by debbugs.gnu.org; 21 Jun 2024 19:01:55 +0000 Received: from localhost ([127.0.0.1]:43738 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sKjWF-000552-3F for submit@debbugs.gnu.org; Fri, 21 Jun 2024 15:01:55 -0400 Received: from mail.goryachev.org ([104.248.201.73]:36134) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sKjWC-00054Z-WF for 71707@debbugs.gnu.org; Fri, 21 Jun 2024 15:01:53 -0400 Received: from localhost.localdomain (213-91-248-88.ip.btc-net.bg [213.91.248.88]) by mail.goryachev.org (Postfix) with ESMTPSA id C192D1202E5; Fri, 21 Jun 2024 22:01:52 +0300 (MSK) Date: Fri, 21 Jun 2024 22:01:08 +0300 Message-ID: <4351173e2417ee0bd95b37a78c2518ee8edb96fc.1718992389.git.igor@goryachev.org> X-Mailer: git-send-email 2.45.1 In-Reply-To: References: MIME-Version: 1.0 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=goryachev.org; s=dkim; t=1718996513; bh=eIdQhg+OHzeNnQnocJ/RAhWVn5/BCx4wpEHm8PpJwsA=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References:MIME-Version:Content-Transfer-Encoding; b=W/k04plpkR9u6i1Csv5ae1mRpoNOb4rp8cy3jvCYGDXeJ+Q3McLSz561AyDQzVS0beH4ovBw5UsPPB7UtIyqi+7UI4hBX3tINDy3QEmGKPyPnm+rGJIlSGPEoMogeydFJCFu39Wp+t9+kj/5YNsAfzuqLbbNZ4oEM4g0RPCHKZg= 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: , Reply-to: Igor Goryachev X-ACL-Warn: , Igor Goryachev via Guix-patches X-Patchwork-Original-From: Igor Goryachev via Guix-patches via From: Igor Goryachev Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches * gnu/packages/elixir.scm (elixir-hex): Remove redundant directory, fix lint warnings. Change-Id: Ic5b29d8ddb9c3d4dc058494cf6cbb5f60a492bb1 --- gnu/packages/elixir.scm | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/gnu/packages/elixir.scm b/gnu/packages/elixir.scm index ace067aa47..e2e9fcc245 100644 --- a/gnu/packages/elixir.scm +++ b/gnu/packages/elixir.scm @@ -174,7 +174,7 @@ (define-public elixir-hex (origin (method git-fetch) (uri (git-reference - (url "https://github.com/hexpm/hex.git") + (url "https://github.com/hexpm/hex") (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 @@ -201,9 +201,14 @@ (define-public elixir-hex (replace 'install (lambda* (#:key inputs outputs #:allow-other-keys) (define X.Y #$(version-major+minor (package-version elixir))) - (define out (string-append (assoc-ref outputs "out") "/lib/elixir/" X.Y "/hex")) + (define out (string-append (assoc-ref outputs "out") + "/lib/elixir/" X.Y "/hex")) (mkdir-p out) - (copy-recursively "_build/prod/lib/hex" out)))))) + (let* ((prod-dir "_build/prod/lib/hex") + (prod-dir-mix (string-append prod-dir "/.mix"))) + (and (directory-exists? prod-dir-mix) + (delete-file-recursively prod-dir-mix)) + (copy-recursively "_build/prod/lib/hex" out))))))) (synopsis "Package manager for the Erlang VM") (description "This project provides tasks that integrate with Mix, Elixir's build