From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:58959) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1f8YMV-0006po-Hl for guix-patches@gnu.org; Tue, 17 Apr 2018 17:42:04 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1f8YMU-0002DD-2W for guix-patches@gnu.org; Tue, 17 Apr 2018 17:42:03 -0400 Received: from debbugs.gnu.org ([208.118.235.43]:50191) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1f8YMT-0002Cj-U9 for guix-patches@gnu.org; Tue, 17 Apr 2018 17:42:01 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1f8YMT-00021h-O1 for guix-patches@gnu.org; Tue, 17 Apr 2018 17:42:01 -0400 Subject: [bug#31121] [PATCH 3/3] gnu: Add osc. Resent-Message-ID: From: =?UTF-8?Q?Tom=C3=A1=C5=A1_?= =?UTF-8?Q?=C4=8Cech?= Date: Tue, 17 Apr 2018 23:40:42 +0200 Message-Id: <20180417214042.31132-1-sleep_walker@gnu.org> In-Reply-To: <87sh7udd03.fsf@fastmail.com> References: <87sh7udd03.fsf@fastmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+kyle=kyleam.com@gnu.org Sender: "Guix-patches" To: 31121@debbugs.gnu.org * gnu/packages/build-tools.scm (osc): New variable. --- gnu/packages/build-tools.scm | 43 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) diff --git a/gnu/packages/build-tools.scm b/gnu/packages/build-tools.scm index 98d12a12f..eb040583b 100644 --- a/gnu/packages/build-tools.scm +++ b/gnu/packages/build-tools.scm @@ -3,6 +3,7 @@ ;;; Copyright © 2017 Corentin Bocquillon ;;; Copyright © 2017, 2018 Tobias Geerinckx-Rice ;;; Copyright © 2018 Fis Trivial +;;; Copyright © 2018 Tomáš Čech ;;; ;;; This file is part of GNU Guix. ;;; @@ -28,6 +29,8 @@ #:use-module (gnu packages) #:use-module (gnu packages compression) #:use-module (gnu packages python) + #:use-module (gnu packages python-crypto) + #:use-module (gnu packages python-web) #:use-module (gnu packages ninja) #:use-module (guix build-system gnu) #:use-module (guix build-system python)) @@ -171,3 +174,43 @@ scripted definition of a software project and outputs @file{Makefile}s or other lower-level build files.") (home-page "https://premake.github.io") (license license:bsd-3))) + +(define-public osc + (package + (name "osc") + (version "0.162.1") + (source + (origin + (method url-fetch) + (uri (string-append "https://github.com/openSUSE/" name + "/archive/" version ".tar.gz")) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0b4kpm96ns4smqyfjysbk2p78d36x44xprpna8zz85q1y5xn57aj")))) + (build-system python-build-system) + (arguments + `(#:python ,python-2 ;; Module is python2 only. + #:phases + (modify-phases %standard-phases + (add-after 'install 'fix-filename-and-remove-unused + (lambda* (#:key outputs #:allow-other-keys) + (let ((bin (string-append (assoc-ref outputs "out") "/bin/"))) + ;; Main osc tool is renamed in spec file, not setup.py, let's + ;; do that too. + (rename-file + (string-append bin "osc-wrapper.py") + (string-append bin "osc")) + ;; Remove unused and broken script. + (delete-file (string-append bin "osc_hotshot.py")) + #t)))))) + (inputs + `(("python2-m2crypto" ,python2-m2crypto) + ("python2-pycurl" ,python2-pycurl) + ("python2-urlgrabber" ,python2-urlgrabber))) + (home-page "https://github.com/openSUSE/osc") + (synopsis "Open Build Service command line tool") + (description "@command{osc} is command line interface to Open Build +Service. It allows you to checkout, commit, perform reviews etc. The vast +majority of the OBS functionality is available via commands and the rest can +be reached via direct API calls.") + (license license:gpl2+))) -- 2.16.3