{"action":"created","comment":{"url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/pulls/comments/25713519","id":25713519,"diff_hunk":"@@ -0,0 +1,89 @@\n+##\n+# Copyright 2009-2013 Ghent University\n+#\n+# This file is part of EasyBuild,\n+# originally created by the HPC team of Ghent University (http://ugent.be/hpc/en),\n+# with support of Ghent University (http://ugent.be/hpc),\n+# the Flemish Supercomputer Centre (VSC) (https://vscentrum.be/nl/en),\n+# the Hercules foundation (http://www.herculesstichting.be/in_English)\n+# and the Department of Economy, Science and Innovation (EWI) (http://www.ewi-vlaanderen.be/en).\n+#\n+# http://github.com/hpcugent/easybuild\n+#\n+# EasyBuild is free software: you can redistribute it and/or modify\n+# it under the terms of the GNU General Public License as published by\n+# the Free Software Foundation v2.\n+#\n+# EasyBuild is distributed in the hope that it will be useful,\n+# but WITHOUT ANY WARRANTY; without even the implied warranty of\n+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\n+# GNU General Public License for more details.\n+#\n+# You should have received a copy of the GNU General Public License\n+# along with EasyBuild.  If not, see <http://www.gnu.org/licenses/>.\n+##\n+\"\"\"\n+EasyBuild support for Ruby Gems, implemented as an easyblock\n+\n+@author: Robert Schmidt (OHRI)\n+\"\"\"\n+\n+from easybuild.framework.extensioneasyblock import ExtensionEasyBlock\n+\n+from easybuild.tools.run import run_cmd\n+\n+class RubyGem(ExtensionEasyBlock):\n+    \"\"\" Builds and installs Ruby Gems \"\"\"\n+\n+    def __init__(self, *args, **kwargs):\n+        super(RubyGem, self).__init__(*args, **kwargs)\n+\n+    def install_ruby_gem(self):\n+        \"\"\"install ruby gems using gem package manager\"\"\"\n+        run_cmd('gem install %s' % (self.ext_src))\n+\n+    def run(self):\n+        \n+        if not self.src:\n+            self.log.error(\"No source found for Ruby Gem %s, required for installation. (src: %s)\" %\n+                           (self.name, self.src))\n+        super(RubyGem, self).run()\n+        if self.src:\n+            self.ext_src = self.src\n+            self.log.debug(\"Installing Ruby gem %s version %s.\" % (self.name, self.version))\n+        else:\n+            self.log.error(\"Do we need to install the newest version?\")\n+\n+        self.install_ruby_gem()\n+\n+    def extract_step(self):\n+        \"\"\"Skip extraction, gemfiles will be installed as downloaded\"\"\"\n+        pass\n+        if len(self.src) > 1:\n+            self.log.error(\"Don't know how to handle R packages with multiple sources.'\")\n+        else:\n+            try:\n+                shutil.copy2(self.src[0]['path'], self.builddir)\n+            except OSError, err:\n+                self.log.error(\"Failed to copy source to build dir: %s\" % err)\n+            self.ext_src = self.src[0]['name']\n+\n+            # set final path since it can't be determined from unpacked sources (used for guessing start_dir)\n+            self.src[0]['finalpath'] = self.builddir\n+\n+    def configure_step(self):\n+        \"\"\"No separate configuration for Ruby Gems.\"\"\"\n+        pass\n+\n+    def build_step(self):\n+        \"\"\"No separate build procedure for Ruby Gems.\"\"\"\n+        pass\n+\n+    def test_step(self):\n+        \"\"\"No separate (standard) test procedure for Ruby Gems.\"\"\"\n+        pass\n+\n+    def install_step(self):\n+        \"\"\"Run install for Ruby Gems\"\"\"\n+        self.install_ruby_gem()\n+","path":"easybuild/easyblocks/generic/rubygem.py","position":89,"original_position":89,"commit_id":"a83fcc248aa73364dfe4431df5ed309ea5f9326f","original_commit_id":"a83fcc248aa73364dfe4431df5ed309ea5f9326f","user":{"login":"boegel","id":620876,"avatar_url":"https://avatars.githubusercontent.com/u/620876?v=3","gravatar_id":"","url":"https://api.github.com/users/boegel","html_url":"https://github.com/boegel","followers_url":"https://api.github.com/users/boegel/followers","following_url":"https://api.github.com/users/boegel/following{/other_user}","gists_url":"https://api.github.com/users/boegel/gists{/gist_id}","starred_url":"https://api.github.com/users/boegel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/boegel/subscriptions","organizations_url":"https://api.github.com/users/boegel/orgs","repos_url":"https://api.github.com/users/boegel/repos","events_url":"https://api.github.com/users/boegel/events{/privacy}","received_events_url":"https://api.github.com/users/boegel/received_events","type":"User","site_admin":false},"body":"kill empty line at the end","created_at":"2015-03-03T18:40:39Z","updated_at":"2015-03-03T18:40:39Z","html_url":"https://github.com/hpcugent/easybuild-easyblocks/pull/565#discussion_r25713519","pull_request_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/pulls/565","_links":{"self":{"href":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/pulls/comments/25713519"},"html":{"href":"https://github.com/hpcugent/easybuild-easyblocks/pull/565#discussion_r25713519"},"pull_request":{"href":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/pulls/565"}}},"pull_request":{"url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/pulls/565","id":30391669,"html_url":"https://github.com/hpcugent/easybuild-easyblocks/pull/565","diff_url":"https://github.com/hpcugent/easybuild-easyblocks/pull/565.diff","patch_url":"https://github.com/hpcugent/easybuild-easyblocks/pull/565.patch","issue_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/issues/565","number":565,"state":"open","locked":false,"title":"{lang} Preliminary versions of an easyblock for ruby and its gems (WIP)","user":{"login":"rjeschmi","id":266522,"avatar_url":"https://avatars.githubusercontent.com/u/266522?v=3","gravatar_id":"","url":"https://api.github.com/users/rjeschmi","html_url":"https://github.com/rjeschmi","followers_url":"https://api.github.com/users/rjeschmi/followers","following_url":"https://api.github.com/users/rjeschmi/following{/other_user}","gists_url":"https://api.github.com/users/rjeschmi/gists{/gist_id}","starred_url":"https://api.github.com/users/rjeschmi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rjeschmi/subscriptions","organizations_url":"https://api.github.com/users/rjeschmi/orgs","repos_url":"https://api.github.com/users/rjeschmi/repos","events_url":"https://api.github.com/users/rjeschmi/events{/privacy}","received_events_url":"https://api.github.com/users/rjeschmi/received_events","type":"User","site_admin":false},"body":"","created_at":"2015-03-03T16:59:38Z","updated_at":"2015-03-03T18:40:39Z","closed_at":null,"merged_at":null,"merge_commit_sha":"094abbfdde7769e02e7f00f79078767c149a7d28","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/pulls/565/commits","review_comments_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/pulls/565/comments","review_comment_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/pulls/comments{/number}","comments_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/issues/565/comments","statuses_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/statuses/a83fcc248aa73364dfe4431df5ed309ea5f9326f","head":{"label":"rjeschmi:ruby-ext-gem","ref":"ruby-ext-gem","sha":"a83fcc248aa73364dfe4431df5ed309ea5f9326f","user":{"login":"rjeschmi","id":266522,"avatar_url":"https://avatars.githubusercontent.com/u/266522?v=3","gravatar_id":"","url":"https://api.github.com/users/rjeschmi","html_url":"https://github.com/rjeschmi","followers_url":"https://api.github.com/users/rjeschmi/followers","following_url":"https://api.github.com/users/rjeschmi/following{/other_user}","gists_url":"https://api.github.com/users/rjeschmi/gists{/gist_id}","starred_url":"https://api.github.com/users/rjeschmi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rjeschmi/subscriptions","organizations_url":"https://api.github.com/users/rjeschmi/orgs","repos_url":"https://api.github.com/users/rjeschmi/repos","events_url":"https://api.github.com/users/rjeschmi/events{/privacy}","received_events_url":"https://api.github.com/users/rjeschmi/received_events","type":"User","site_admin":false},"repo":{"id":26606344,"name":"easybuild-easyblocks","full_name":"rjeschmi/easybuild-easyblocks","owner":{"login":"rjeschmi","id":266522,"avatar_url":"https://avatars.githubusercontent.com/u/266522?v=3","gravatar_id":"","url":"https://api.github.com/users/rjeschmi","html_url":"https://github.com/rjeschmi","followers_url":"https://api.github.com/users/rjeschmi/followers","following_url":"https://api.github.com/users/rjeschmi/following{/other_user}","gists_url":"https://api.github.com/users/rjeschmi/gists{/gist_id}","starred_url":"https://api.github.com/users/rjeschmi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rjeschmi/subscriptions","organizations_url":"https://api.github.com/users/rjeschmi/orgs","repos_url":"https://api.github.com/users/rjeschmi/repos","events_url":"https://api.github.com/users/rjeschmi/events{/privacy}","received_events_url":"https://api.github.com/users/rjeschmi/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/rjeschmi/easybuild-easyblocks","description":"Collection of easyblock that implement support for building and installing software with EasyBuild.","fork":true,"url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks","forks_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/forks","keys_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/keys{/key_id}","collaborators_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/teams","hooks_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/hooks","issue_events_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/issues/events{/number}","events_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/events","assignees_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/assignees{/user}","branches_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/branches{/branch}","tags_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/tags","blobs_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/git/refs{/sha}","trees_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/git/trees{/sha}","statuses_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/statuses/{sha}","languages_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/languages","stargazers_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/stargazers","contributors_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/contributors","subscribers_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/subscribers","subscription_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/subscription","commits_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/commits{/sha}","git_commits_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/git/commits{/sha}","comments_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/comments{/number}","issue_comment_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/issues/comments{/number}","contents_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/contents/{+path}","compare_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/compare/{base}...{head}","merges_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/merges","archive_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/downloads","issues_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/issues{/number}","pulls_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/pulls{/number}","milestones_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/milestones{/number}","notifications_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/labels{/name}","releases_url":"https://api.github.com/repos/rjeschmi/easybuild-easyblocks/releases{/id}","created_at":"2014-11-13T20:25:28Z","updated_at":"2014-11-13T20:25:29Z","pushed_at":"2015-03-03T16:59:06Z","git_url":"git://github.com/rjeschmi/easybuild-easyblocks.git","ssh_url":"git@github.com:rjeschmi/easybuild-easyblocks.git","clone_url":"https://github.com/rjeschmi/easybuild-easyblocks.git","svn_url":"https://github.com/rjeschmi/easybuild-easyblocks","homepage":"http://hpcugent.github.com/easybuild/","size":7755,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"hpcugent:develop","ref":"develop","sha":"bd190c8485fe087f47805a27a997095e26dc0b38","user":{"login":"hpcugent","id":1515263,"avatar_url":"https://avatars.githubusercontent.com/u/1515263?v=3","gravatar_id":"","url":"https://api.github.com/users/hpcugent","html_url":"https://github.com/hpcugent","followers_url":"https://api.github.com/users/hpcugent/followers","following_url":"https://api.github.com/users/hpcugent/following{/other_user}","gists_url":"https://api.github.com/users/hpcugent/gists{/gist_id}","starred_url":"https://api.github.com/users/hpcugent/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hpcugent/subscriptions","organizations_url":"https://api.github.com/users/hpcugent/orgs","repos_url":"https://api.github.com/users/hpcugent/repos","events_url":"https://api.github.com/users/hpcugent/events{/privacy}","received_events_url":"https://api.github.com/users/hpcugent/received_events","type":"Organization","site_admin":false},"repo":{"id":6228378,"name":"easybuild-easyblocks","full_name":"hpcugent/easybuild-easyblocks","owner":{"login":"hpcugent","id":1515263,"avatar_url":"https://avatars.githubusercontent.com/u/1515263?v=3","gravatar_id":"","url":"https://api.github.com/users/hpcugent","html_url":"https://github.com/hpcugent","followers_url":"https://api.github.com/users/hpcugent/followers","following_url":"https://api.github.com/users/hpcugent/following{/other_user}","gists_url":"https://api.github.com/users/hpcugent/gists{/gist_id}","starred_url":"https://api.github.com/users/hpcugent/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hpcugent/subscriptions","organizations_url":"https://api.github.com/users/hpcugent/orgs","repos_url":"https://api.github.com/users/hpcugent/repos","events_url":"https://api.github.com/users/hpcugent/events{/privacy}","received_events_url":"https://api.github.com/users/hpcugent/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/hpcugent/easybuild-easyblocks","description":"Collection of easyblocks that implement support for building and installing software with EasyBuild.","fork":false,"url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks","forks_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/forks","keys_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/keys{/key_id}","collaborators_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/teams","hooks_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/hooks","issue_events_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/issues/events{/number}","events_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/events","assignees_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/assignees{/user}","branches_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/branches{/branch}","tags_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/tags","blobs_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/git/refs{/sha}","trees_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/git/trees{/sha}","statuses_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/statuses/{sha}","languages_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/languages","stargazers_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/stargazers","contributors_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/contributors","subscribers_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/subscribers","subscription_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/subscription","commits_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/commits{/sha}","git_commits_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/git/commits{/sha}","comments_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/comments{/number}","issue_comment_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/issues/comments{/number}","contents_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/contents/{+path}","compare_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/compare/{base}...{head}","merges_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/merges","archive_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/downloads","issues_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/issues{/number}","pulls_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/pulls{/number}","milestones_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/milestones{/number}","notifications_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/labels{/name}","releases_url":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/releases{/id}","created_at":"2012-10-15T14:31:19Z","updated_at":"2015-02-12T19:49:22Z","pushed_at":"2015-03-03T10:07:19Z","git_url":"git://github.com/hpcugent/easybuild-easyblocks.git","ssh_url":"git@github.com:hpcugent/easybuild-easyblocks.git","clone_url":"https://github.com/hpcugent/easybuild-easyblocks.git","svn_url":"https://github.com/hpcugent/easybuild-easyblocks","homepage":"http://hpcugent.github.com/easybuild/","size":11101,"stargazers_count":19,"watchers_count":19,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":59,"mirror_url":null,"open_issues_count":93,"forks":59,"open_issues":93,"watchers":19,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/pulls/565"},"html":{"href":"https://github.com/hpcugent/easybuild-easyblocks/pull/565"},"issue":{"href":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/issues/565"},"comments":{"href":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/issues/565/comments"},"review_comments":{"href":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/pulls/565/comments"},"review_comment":{"href":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/pulls/565/commits"},"statuses":{"href":"https://api.github.com/repos/hpcugent/easybuild-easyblocks/statuses/a83fcc248aa73364dfe4431df5ed309ea5f9326f"}}}}