Bug 187483 - port rubygems for hammer_cli_foreman
Summary: port rubygems for hammer_cli_foreman
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Steve Wills
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-03-12 15:10 UTC by Michael Moll
Modified: 2014-03-13 19:09 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Moll freebsd_committer freebsd_triage 2014-03-12 15:10:00 UTC
http://space.kvedulv.de/hammer.tar.gz contains all the needed ports to use hammer on FreeBSD.

Hammer is the CLI tool to use with Foreman (http://theforeman.org). This is a continuation of the efforts to bring Foreman onto FreeBSD, after net/foreman-proxy. :)
Comment 1 Steve Wills freebsd_committer freebsd_triage 2014-03-12 16:59:19 UTC
Responsible Changed
From-To: freebsd-ports-bugs->swills

I'll take it.
Comment 2 dfilter service freebsd_committer freebsd_triage 2014-03-13 18:01:53 UTC
Author: swills
Date: Thu Mar 13 18:01:44 2014
New Revision: 348110
URL: http://svnweb.freebsd.org/changeset/ports/348110
QAT: https://qat.redports.org/buildarchive/r348110/

Log:
  This gem contains Foreman API bindings for the Ruby language.
  The bindings are generated from API documentation using Apidoc tool.
  
  WWW: https://github.com/theforeman/foreman_api
  
  PR:		ports/187483
  Submitted by:	Michael Moll <kvedulv@kvedulv.de>

Added:
  head/devel/rubygem-foreman_api/
  head/devel/rubygem-foreman_api/Makefile   (contents, props changed)
  head/devel/rubygem-foreman_api/distinfo   (contents, props changed)
  head/devel/rubygem-foreman_api/pkg-descr   (contents, props changed)
Modified:
  head/devel/Makefile

Modified: head/devel/Makefile
==============================================================================
--- head/devel/Makefile	Thu Mar 13 17:50:30 2014	(r348109)
+++ head/devel/Makefile	Thu Mar 13 18:01:44 2014	(r348110)
@@ -4205,6 +4205,7 @@
     SUBDIR += rubygem-fog
     SUBDIR += rubygem-font-awesome-rails
     SUBDIR += rubygem-foreman
+    SUBDIR += rubygem-foreman_api
     SUBDIR += rubygem-formatador
     SUBDIR += rubygem-gdata
     SUBDIR += rubygem-gem_plugin

Added: head/devel/rubygem-foreman_api/Makefile
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/devel/rubygem-foreman_api/Makefile	Thu Mar 13 18:01:44 2014	(r348110)
@@ -0,0 +1,22 @@
+# Created by: Michael Moll <kvedulv@kvedulv.de>
+# $FreeBSD$
+
+PORTNAME=	foreman_api
+PORTVERSION=	0.1.11
+CATEGORIES=	devel ruby
+MASTER_SITES=	RG
+
+MAINTAINER=	ruby@FreeBSD.org
+COMMENT=	Helps you to use Foreman API calls from your app
+
+LICENSE=	MIT
+
+RUN_DEPENDS=	rubygem-json>=1.8.1:${PORTSDIR}/devel/rubygem-json \
+		rubygem-oauth>=0.4.7:${PORTSDIR}/net/rubygem-oauth \
+		rubygem-rest-client>=1.6.1:${PORTSDIR}/www/rubygem-rest-client
+
+USE_RUBY=	yes
+USE_RUBYGEMS=	yes
+RUBYGEM_AUTOPLIST=	yes
+
+.include <bsd.port.mk>

Added: head/devel/rubygem-foreman_api/distinfo
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/devel/rubygem-foreman_api/distinfo	Thu Mar 13 18:01:44 2014	(r348110)
@@ -0,0 +1,2 @@
+SHA256 (rubygem/foreman_api-0.1.11.gem) = e15c28e5f6631f433f22cf4b2130e52562a3ab32a3929af95a1ef37a69041953
+SIZE (rubygem/foreman_api-0.1.11.gem) = 118272

Added: head/devel/rubygem-foreman_api/pkg-descr
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/devel/rubygem-foreman_api/pkg-descr	Thu Mar 13 18:01:44 2014	(r348110)
@@ -0,0 +1,4 @@
+This gem contains Foreman API bindings for the Ruby language.
+The bindings are generated from API documentation using Apidoc tool.
+
+WWW: https://github.com/theforeman/foreman_api
_______________________________________________
svn-ports-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-ports-all
To unsubscribe, send any mail to "svn-ports-all-unsubscribe@freebsd.org"
Comment 3 dfilter service freebsd_committer freebsd_triage 2014-03-13 18:30:26 UTC
Author: swills
Date: Thu Mar 13 18:30:16 2014
New Revision: 348112
URL: http://svnweb.freebsd.org/changeset/ports/348112
QAT: https://qat.redports.org/buildarchive/r348112/

Log:
  Hammer is a generic clamp-based CLI framework. Hammer-cli provides just
  the core functionality. The core is extensible using plugins that contain
  application-specific commands.
  
  WWW: https://github.com/theforeman/hammer-cli
  
  PR:		ports/187483
  Submitted by:	Michael Moll <kvedulv@kvedulv.de>

Added:
  head/sysutils/rubygem-hammer_cli/
  head/sysutils/rubygem-hammer_cli/Makefile   (contents, props changed)
  head/sysutils/rubygem-hammer_cli/distinfo   (contents, props changed)
  head/sysutils/rubygem-hammer_cli/files/
  head/sysutils/rubygem-hammer_cli/files/patch-bin__hammer   (contents, props changed)
  head/sysutils/rubygem-hammer_cli/pkg-descr   (contents, props changed)
Modified:
  head/sysutils/Makefile

Modified: head/sysutils/Makefile
==============================================================================
--- head/sysutils/Makefile	Thu Mar 13 18:03:06 2014	(r348111)
+++ head/sysutils/Makefile	Thu Mar 13 18:30:16 2014	(r348112)
@@ -805,6 +805,7 @@
     SUBDIR += rubygem-guard-livereload
     SUBDIR += rubygem-guard-minitest
     SUBDIR += rubygem-guard-rspec
+    SUBDIR += rubygem-hammer_cli
     SUBDIR += rubygem-hiera
     SUBDIR += rubygem-hiera-json
     SUBDIR += rubygem-hiera-puppet

Added: head/sysutils/rubygem-hammer_cli/Makefile
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/sysutils/rubygem-hammer_cli/Makefile	Thu Mar 13 18:30:16 2014	(r348112)
@@ -0,0 +1,29 @@
+# Created by: Michael Moll <kvedulv@kvedulv.de>
+# $FreeBSD$
+
+PORTNAME=	hammer_cli
+PORTVERSION=	0.0.18
+CATEGORIES=	sysutils ruby
+MASTER_SITES=	RG
+
+MAINTAINER=	ruby@FreeBSD.org
+COMMENT=	Provides CLI interfaces for Ruby apps
+
+LICENSE=	GPLv3
+
+RUN_DEPENDS=	rubygem-awesome_print>=1.1.0:${PORTSDIR}/devel/rubygem-awesome_print \
+		rubygem-clamp>=0.6.3:${PORTSDIR}/devel/rubygem-clamp \
+		rubygem-fastercsv>=1.5.5:${PORTSDIR}/devel/rubygem-fastercsv \
+		rubygem-highline>=1.6.20:${PORTSDIR}/devel/rubygem-highline \
+		rubygem-logging>=1.8.1:${PORTSDIR}/devel/rubygem-logging \
+		rubygem-mime-types>=1.0:${PORTSDIR}/misc/rubygem-mime-types \
+		rubygem-rest-client>=1.6.7:${PORTSDIR}/www/rubygem-rest-client \
+		rubygem-table_print>=1.5.1:${PORTSDIR}/devel/rubygem-table_print
+
+USE_RUBY=	yes
+USE_RUBYGEMS=	yes
+RUBYGEM_AUTOPLIST=	yes
+
+PLIST_FILES=	bin/hammer
+
+.include <bsd.port.mk>

Added: head/sysutils/rubygem-hammer_cli/distinfo
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/sysutils/rubygem-hammer_cli/distinfo	Thu Mar 13 18:30:16 2014	(r348112)
@@ -0,0 +1,2 @@
+SHA256 (rubygem/hammer_cli-0.0.18.gem) = 6cbda00ba509029e8fc96edda0d1076d285d1f97eeb0b8590f4b939106ec023c
+SIZE (rubygem/hammer_cli-0.0.18.gem) = 80896

Added: head/sysutils/rubygem-hammer_cli/files/patch-bin__hammer
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/sysutils/rubygem-hammer_cli/files/patch-bin__hammer	Thu Mar 13 18:30:16 2014	(r348112)
@@ -0,0 +1,11 @@
+--- bin/hammer.orig	2014-03-12 11:07:16.000000000 +0100
++++ bin/hammer	2014-03-12 11:07:33.000000000 +0100
+@@ -20,7 +20,7 @@
+ # load user's settings
+ require 'hammer_cli/settings'
+ 
+-CFG_PATH = ['./config/cli_config.yml', '~/.foreman/cli_config.yml', '/etc/foreman/cli_config.yml']
++CFG_PATH = ['./config/cli_config.yml', '~/.foreman/cli_config.yml', '/etc/foreman/cli_config.yml', "#{::RbConfig::CONFIG['sysconfdir']}/foreman/cli_config.yml"].uniq
+ 
+ if preparser.config
+   CFG_PATH.unshift preparser.config

Added: head/sysutils/rubygem-hammer_cli/pkg-descr
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/sysutils/rubygem-hammer_cli/pkg-descr	Thu Mar 13 18:30:16 2014	(r348112)
@@ -0,0 +1,5 @@
+Hammer is a generic clamp-based CLI framework. Hammer-cli provides just
+the core functionality. The core is extensible using plugins that contain
+application-specific commands.
+
+WWW: https://github.com/theforeman/hammer-cli
_______________________________________________
svn-ports-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-ports-all
To unsubscribe, send any mail to "svn-ports-all-unsubscribe@freebsd.org"
Comment 4 dfilter service freebsd_committer freebsd_triage 2014-03-13 18:49:35 UTC
Author: swills
Date: Thu Mar 13 18:49:27 2014
New Revision: 348116
URL: http://svnweb.freebsd.org/changeset/ports/348116
QAT: https://qat.redports.org/buildarchive/r348116/

Log:
  This Hammer CLI plugin contains set of commands for Foreman.
  
  WWW: https://github.com/theforeman/hammer-cli-foreman
  
  PR:		ports/187483
  Submitted by:	Michael Moll <kvedulv@kvedulv.de>

Added:
  head/sysutils/rubygem-hammer_cli_foreman/
  head/sysutils/rubygem-hammer_cli_foreman/Makefile   (contents, props changed)
  head/sysutils/rubygem-hammer_cli_foreman/distinfo   (contents, props changed)
  head/sysutils/rubygem-hammer_cli_foreman/files/
  head/sysutils/rubygem-hammer_cli_foreman/files/patch-lib__hammer_cli_foreman__commands.rb   (contents, props changed)
  head/sysutils/rubygem-hammer_cli_foreman/pkg-descr   (contents, props changed)
Modified:
  head/sysutils/Makefile

Modified: head/sysutils/Makefile
==============================================================================
--- head/sysutils/Makefile	Thu Mar 13 18:40:16 2014	(r348115)
+++ head/sysutils/Makefile	Thu Mar 13 18:49:27 2014	(r348116)
@@ -806,6 +806,7 @@
     SUBDIR += rubygem-guard-minitest
     SUBDIR += rubygem-guard-rspec
     SUBDIR += rubygem-hammer_cli
+    SUBDIR += rubygem-hammer_cli_foreman
     SUBDIR += rubygem-hiera
     SUBDIR += rubygem-hiera-json
     SUBDIR += rubygem-hiera-puppet

Added: head/sysutils/rubygem-hammer_cli_foreman/Makefile
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/sysutils/rubygem-hammer_cli_foreman/Makefile	Thu Mar 13 18:49:27 2014	(r348116)
@@ -0,0 +1,21 @@
+# Created by: Michael Moll <kvedulv@kvedulv.de>
+# $FreeBSD$
+
+PORTNAME=	hammer_cli_foreman
+PORTVERSION=	0.0.18
+CATEGORIES=	sysutils ruby
+MASTER_SITES=	RG
+
+MAINTAINER=	ruby@FreeBSD.org
+COMMENT=	Foreman commands for Hammer CLI
+
+LICENSE=	GPLv3
+
+RUN_DEPENDS=	rubygem-foreman_api>=0.1.11:${PORTSDIR}/devel/rubygem-foreman_api \
+		rubygem-hammer_cli>=0.0.18:${PORTSDIR}/sysutils/rubygem-hammer_cli
+
+USE_RUBY=	yes
+USE_RUBYGEMS=	yes
+RUBYGEM_AUTOPLIST=	yes
+
+.include <bsd.port.mk>

Added: head/sysutils/rubygem-hammer_cli_foreman/distinfo
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/sysutils/rubygem-hammer_cli_foreman/distinfo	Thu Mar 13 18:49:27 2014	(r348116)
@@ -0,0 +1,2 @@
+SHA256 (rubygem/hammer_cli_foreman-0.0.18.gem) = 97a7310e001726bf8bc0004bb9f08c87650e224fac351b1e3f8b2dc593e05337
+SIZE (rubygem/hammer_cli_foreman-0.0.18.gem) = 48640

Added: head/sysutils/rubygem-hammer_cli_foreman/files/patch-lib__hammer_cli_foreman__commands.rb
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/sysutils/rubygem-hammer_cli_foreman/files/patch-lib__hammer_cli_foreman__commands.rb	Thu Mar 13 18:49:27 2014	(r348116)
@@ -0,0 +1,28 @@
+--- lib/hammer_cli_foreman/commands.rb.orig	2014-03-12 11:03:33.000000000 +0100
++++ lib/hammer_cli_foreman/commands.rb	2014-03-12 11:03:49.000000000 +0100
+@@ -60,9 +60,9 @@
+     end
+ 
+     def execute
+-      if respond_to?(:page) && respond_to?(:per_page)
+-        self.page ||= 1
+-        self.per_page ||= HammerCLI::Settings.get(:ui, :per_page) || DEFAULT_PER_PAGE
++      if respond_to?(:option_page) && respond_to?(:option_per_page)
++        self.option_page ||= 1
++        self.option_per_page ||= HammerCLI::Settings.get(:ui, :per_page) || DEFAULT_PER_PAGE
+         browse_collection
+       else
+         retrieve_and_print
+@@ -79,10 +79,10 @@
+       while list_next do
+         d = retrieve_and_print
+ 
+-        if (d.size >= self.per_page.to_i) && interactive?
++        if (d.size >= self.option_per_page.to_i) && interactive?
+           answer = ask("List next page? (Y/n): ").downcase
+           list_next = (answer == 'y' || answer == '')
+-          self.page += 1
++          self.option_page += 1
+         else
+           list_next = false
+         end

Added: head/sysutils/rubygem-hammer_cli_foreman/pkg-descr
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/sysutils/rubygem-hammer_cli_foreman/pkg-descr	Thu Mar 13 18:49:27 2014	(r348116)
@@ -0,0 +1,3 @@
+This Hammer CLI plugin contains set of commands for Foreman.
+
+WWW: https://github.com/theforeman/hammer-cli-foreman
_______________________________________________
svn-ports-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-ports-all
To unsubscribe, send any mail to "svn-ports-all-unsubscribe@freebsd.org"
Comment 5 Steve Wills freebsd_committer freebsd_triage 2014-03-13 19:09:22 UTC
State Changed
From-To: open->closed

new ports added, with minor changes. Thanks!