{"action":"created","comment":{"url":"https://api.github.com/repos/theforeman/foreman-infra/pulls/comments/170253641","pull_request_review_id":98914735,"id":170253641,"diff_hunk":"@@ -0,0 +1,61 @@\n+def packages_to_build\n+\n+pipeline {\n+    agent { label 'rpmbuild' }\n+\n+    options {\n+        timestamps()\n+        timeout(time: 2, unit: 'HOURS')\n+        ansiColor('xterm')\n+        buildDiscarder(logRotator(numToKeepStr: '15'))\n+    }\n+\n+    stages {\n+        stage('Clone Packaging') {\n+            steps {\n+\n+                deleteDir()\n+                checkout changelog: true, poll: false, scm: [\n+                    $class: 'GitSCM',\n+                    branches: [[name: '${ghprbActualCommit}']],\n+                    doGenerateSubmoduleConfigurations: false,\n+                    extensions: [[$class: 'PreBuildMerge', options: [fastForwardMode: 'FF', mergeRemote: 'origin', mergeStrategy: 'default', mergeTarget: '${ghprbTargetBranch}']]],\n+                    submoduleCfg: [],\n+                    userRemoteConfigs: [\n+                        [refspec: '+refs/pull/${ghprbPullId}/*:refs/remotes/origin/pr/${ghprbPullId}/*', url: 'https://github.com/${ghprbGhRepository}']\n+                    ]\n+                ]\n+\n+            }\n+        }\n+\n+        stage('Find Packages to Build') {\n+            steps {\n+\n+                script {\n+                    changed_packages = sh(returnStdout: true, script: \"git diff origin/${ghprbTargetBranch} --name-only -- 'packages/**.spec' | cut -d'/' -f2 |sort -u\").trim()","path":"puppet/modules/jenkins_job_builder/files/theforeman.org/pipelines/lib/packaging.groovy","position":36,"original_position":36,"commit_id":"d9c975f9cbb3620fd8f79330347c6ef35ab40d70","original_commit_id":"d9c975f9cbb3620fd8f79330347c6ef35ab40d70","user":{"login":"ekohl","id":155810,"avatar_url":"https://avatars0.githubusercontent.com/u/155810?v=4","gravatar_id":"","url":"https://api.github.com/users/ekohl","html_url":"https://github.com/ekohl","followers_url":"https://api.github.com/users/ekohl/followers","following_url":"https://api.github.com/users/ekohl/following{/other_user}","gists_url":"https://api.github.com/users/ekohl/gists{/gist_id}","starred_url":"https://api.github.com/users/ekohl/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ekohl/subscriptions","organizations_url":"https://api.github.com/users/ekohl/orgs","repos_url":"https://api.github.com/users/ekohl/repos","events_url":"https://api.github.com/users/ekohl/events{/privacy}","received_events_url":"https://api.github.com/users/ekohl/received_events","type":"User","site_admin":false},"body":"Rather than cut, would dirname + basename be possible? That wouldn't assume a directory structure making it work for older branches too.","created_at":"2018-02-23T13:43:03Z","updated_at":"2018-02-23T13:44:55Z","html_url":"https://github.com/theforeman/foreman-infra/pull/485#discussion_r170253641","pull_request_url":"https://api.github.com/repos/theforeman/foreman-infra/pulls/485","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/theforeman/foreman-infra/pulls/comments/170253641"},"html":{"href":"https://github.com/theforeman/foreman-infra/pull/485#discussion_r170253641"},"pull_request":{"href":"https://api.github.com/repos/theforeman/foreman-infra/pulls/485"}}},"pull_request":{"url":"https://api.github.com/repos/theforeman/foreman-infra/pulls/485","id":170510648,"html_url":"https://github.com/theforeman/foreman-infra/pull/485","diff_url":"https://github.com/theforeman/foreman-infra/pull/485.diff","patch_url":"https://github.com/theforeman/foreman-infra/pull/485.patch","issue_url":"https://api.github.com/repos/theforeman/foreman-infra/issues/485","number":485,"state":"open","locked":false,"title":"allow for packaging being tested in a pipeline","user":{"login":"evgeni","id":94284,"avatar_url":"https://avatars3.githubusercontent.com/u/94284?v=4","gravatar_id":"","url":"https://api.github.com/users/evgeni","html_url":"https://github.com/evgeni","followers_url":"https://api.github.com/users/evgeni/followers","following_url":"https://api.github.com/users/evgeni/following{/other_user}","gists_url":"https://api.github.com/users/evgeni/gists{/gist_id}","starred_url":"https://api.github.com/users/evgeni/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/evgeni/subscriptions","organizations_url":"https://api.github.com/users/evgeni/orgs","repos_url":"https://api.github.com/users/evgeni/repos","events_url":"https://api.github.com/users/evgeni/events{/privacy}","received_events_url":"https://api.github.com/users/evgeni/received_events","type":"User","site_admin":false},"body":"the code is based on tfmROR51.groovy, which should also migrate to this\r\nnew lib as soon as obal supports copr properly","created_at":"2018-02-21T15:54:49Z","updated_at":"2018-02-23T13:44:56Z","closed_at":null,"merged_at":null,"merge_commit_sha":"1256bef5c8ff30a84926681cc8f795ec5adcb123","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/theforeman/foreman-infra/pulls/485/commits","review_comments_url":"https://api.github.com/repos/theforeman/foreman-infra/pulls/485/comments","review_comment_url":"https://api.github.com/repos/theforeman/foreman-infra/pulls/comments{/number}","comments_url":"https://api.github.com/repos/theforeman/foreman-infra/issues/485/comments","statuses_url":"https://api.github.com/repos/theforeman/foreman-infra/statuses/d9c975f9cbb3620fd8f79330347c6ef35ab40d70","head":{"label":"evgeni:packaging-pipe","ref":"packaging-pipe","sha":"d9c975f9cbb3620fd8f79330347c6ef35ab40d70","user":{"login":"evgeni","id":94284,"avatar_url":"https://avatars3.githubusercontent.com/u/94284?v=4","gravatar_id":"","url":"https://api.github.com/users/evgeni","html_url":"https://github.com/evgeni","followers_url":"https://api.github.com/users/evgeni/followers","following_url":"https://api.github.com/users/evgeni/following{/other_user}","gists_url":"https://api.github.com/users/evgeni/gists{/gist_id}","starred_url":"https://api.github.com/users/evgeni/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/evgeni/subscriptions","organizations_url":"https://api.github.com/users/evgeni/orgs","repos_url":"https://api.github.com/users/evgeni/repos","events_url":"https://api.github.com/users/evgeni/events{/privacy}","received_events_url":"https://api.github.com/users/evgeni/received_events","type":"User","site_admin":false},"repo":{"id":90037256,"name":"foreman-infra","full_name":"evgeni/foreman-infra","owner":{"login":"evgeni","id":94284,"avatar_url":"https://avatars3.githubusercontent.com/u/94284?v=4","gravatar_id":"","url":"https://api.github.com/users/evgeni","html_url":"https://github.com/evgeni","followers_url":"https://api.github.com/users/evgeni/followers","following_url":"https://api.github.com/users/evgeni/following{/other_user}","gists_url":"https://api.github.com/users/evgeni/gists{/gist_id}","starred_url":"https://api.github.com/users/evgeni/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/evgeni/subscriptions","organizations_url":"https://api.github.com/users/evgeni/orgs","repos_url":"https://api.github.com/users/evgeni/repos","events_url":"https://api.github.com/users/evgeni/events{/privacy}","received_events_url":"https://api.github.com/users/evgeni/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/evgeni/foreman-infra","description":"Puppet modules and scripts to manage Foreman project infrastructure","fork":true,"url":"https://api.github.com/repos/evgeni/foreman-infra","forks_url":"https://api.github.com/repos/evgeni/foreman-infra/forks","keys_url":"https://api.github.com/repos/evgeni/foreman-infra/keys{/key_id}","collaborators_url":"https://api.github.com/repos/evgeni/foreman-infra/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/evgeni/foreman-infra/teams","hooks_url":"https://api.github.com/repos/evgeni/foreman-infra/hooks","issue_events_url":"https://api.github.com/repos/evgeni/foreman-infra/issues/events{/number}","events_url":"https://api.github.com/repos/evgeni/foreman-infra/events","assignees_url":"https://api.github.com/repos/evgeni/foreman-infra/assignees{/user}","branches_url":"https://api.github.com/repos/evgeni/foreman-infra/branches{/branch}","tags_url":"https://api.github.com/repos/evgeni/foreman-infra/tags","blobs_url":"https://api.github.com/repos/evgeni/foreman-infra/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/evgeni/foreman-infra/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/evgeni/foreman-infra/git/refs{/sha}","trees_url":"https://api.github.com/repos/evgeni/foreman-infra/git/trees{/sha}","statuses_url":"https://api.github.com/repos/evgeni/foreman-infra/statuses/{sha}","languages_url":"https://api.github.com/repos/evgeni/foreman-infra/languages","stargazers_url":"https://api.github.com/repos/evgeni/foreman-infra/stargazers","contributors_url":"https://api.github.com/repos/evgeni/foreman-infra/contributors","subscribers_url":"https://api.github.com/repos/evgeni/foreman-infra/subscribers","subscription_url":"https://api.github.com/repos/evgeni/foreman-infra/subscription","commits_url":"https://api.github.com/repos/evgeni/foreman-infra/commits{/sha}","git_commits_url":"https://api.github.com/repos/evgeni/foreman-infra/git/commits{/sha}","comments_url":"https://api.github.com/repos/evgeni/foreman-infra/comments{/number}","issue_comment_url":"https://api.github.com/repos/evgeni/foreman-infra/issues/comments{/number}","contents_url":"https://api.github.com/repos/evgeni/foreman-infra/contents/{+path}","compare_url":"https://api.github.com/repos/evgeni/foreman-infra/compare/{base}...{head}","merges_url":"https://api.github.com/repos/evgeni/foreman-infra/merges","archive_url":"https://api.github.com/repos/evgeni/foreman-infra/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/evgeni/foreman-infra/downloads","issues_url":"https://api.github.com/repos/evgeni/foreman-infra/issues{/number}","pulls_url":"https://api.github.com/repos/evgeni/foreman-infra/pulls{/number}","milestones_url":"https://api.github.com/repos/evgeni/foreman-infra/milestones{/number}","notifications_url":"https://api.github.com/repos/evgeni/foreman-infra/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/evgeni/foreman-infra/labels{/name}","releases_url":"https://api.github.com/repos/evgeni/foreman-infra/releases{/id}","deployments_url":"https://api.github.com/repos/evgeni/foreman-infra/deployments","created_at":"2017-05-02T13:34:49Z","updated_at":"2017-05-02T13:34:51Z","pushed_at":"2018-02-22T16:36:05Z","git_url":"git://github.com/evgeni/foreman-infra.git","ssh_url":"git@github.com:evgeni/foreman-infra.git","clone_url":"https://github.com/evgeni/foreman-infra.git","svn_url":"https://github.com/evgeni/foreman-infra","homepage":"","size":1522,"stargazers_count":0,"watchers_count":0,"language":"HTML","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":null,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"theforeman:master","ref":"master","sha":"4afb997715c82d9d76082f8c6567fe0b6f4a75cd","user":{"login":"theforeman","id":1439844,"avatar_url":"https://avatars2.githubusercontent.com/u/1439844?v=4","gravatar_id":"","url":"https://api.github.com/users/theforeman","html_url":"https://github.com/theforeman","followers_url":"https://api.github.com/users/theforeman/followers","following_url":"https://api.github.com/users/theforeman/following{/other_user}","gists_url":"https://api.github.com/users/theforeman/gists{/gist_id}","starred_url":"https://api.github.com/users/theforeman/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/theforeman/subscriptions","organizations_url":"https://api.github.com/users/theforeman/orgs","repos_url":"https://api.github.com/users/theforeman/repos","events_url":"https://api.github.com/users/theforeman/events{/privacy}","received_events_url":"https://api.github.com/users/theforeman/received_events","type":"Organization","site_admin":false},"repo":{"id":5750224,"name":"foreman-infra","full_name":"theforeman/foreman-infra","owner":{"login":"theforeman","id":1439844,"avatar_url":"https://avatars2.githubusercontent.com/u/1439844?v=4","gravatar_id":"","url":"https://api.github.com/users/theforeman","html_url":"https://github.com/theforeman","followers_url":"https://api.github.com/users/theforeman/followers","following_url":"https://api.github.com/users/theforeman/following{/other_user}","gists_url":"https://api.github.com/users/theforeman/gists{/gist_id}","starred_url":"https://api.github.com/users/theforeman/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/theforeman/subscriptions","organizations_url":"https://api.github.com/users/theforeman/orgs","repos_url":"https://api.github.com/users/theforeman/repos","events_url":"https://api.github.com/users/theforeman/events{/privacy}","received_events_url":"https://api.github.com/users/theforeman/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/theforeman/foreman-infra","description":"Puppet modules and scripts to manage Foreman project infrastructure","fork":false,"url":"https://api.github.com/repos/theforeman/foreman-infra","forks_url":"https://api.github.com/repos/theforeman/foreman-infra/forks","keys_url":"https://api.github.com/repos/theforeman/foreman-infra/keys{/key_id}","collaborators_url":"https://api.github.com/repos/theforeman/foreman-infra/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/theforeman/foreman-infra/teams","hooks_url":"https://api.github.com/repos/theforeman/foreman-infra/hooks","issue_events_url":"https://api.github.com/repos/theforeman/foreman-infra/issues/events{/number}","events_url":"https://api.github.com/repos/theforeman/foreman-infra/events","assignees_url":"https://api.github.com/repos/theforeman/foreman-infra/assignees{/user}","branches_url":"https://api.github.com/repos/theforeman/foreman-infra/branches{/branch}","tags_url":"https://api.github.com/repos/theforeman/foreman-infra/tags","blobs_url":"https://api.github.com/repos/theforeman/foreman-infra/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/theforeman/foreman-infra/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/theforeman/foreman-infra/git/refs{/sha}","trees_url":"https://api.github.com/repos/theforeman/foreman-infra/git/trees{/sha}","statuses_url":"https://api.github.com/repos/theforeman/foreman-infra/statuses/{sha}","languages_url":"https://api.github.com/repos/theforeman/foreman-infra/languages","stargazers_url":"https://api.github.com/repos/theforeman/foreman-infra/stargazers","contributors_url":"https://api.github.com/repos/theforeman/foreman-infra/contributors","subscribers_url":"https://api.github.com/repos/theforeman/foreman-infra/subscribers","subscription_url":"https://api.github.com/repos/theforeman/foreman-infra/subscription","commits_url":"https://api.github.com/repos/theforeman/foreman-infra/commits{/sha}","git_commits_url":"https://api.github.com/repos/theforeman/foreman-infra/git/commits{/sha}","comments_url":"https://api.github.com/repos/theforeman/foreman-infra/comments{/number}","issue_comment_url":"https://api.github.com/repos/theforeman/foreman-infra/issues/comments{/number}","contents_url":"https://api.github.com/repos/theforeman/foreman-infra/contents/{+path}","compare_url":"https://api.github.com/repos/theforeman/foreman-infra/compare/{base}...{head}","merges_url":"https://api.github.com/repos/theforeman/foreman-infra/merges","archive_url":"https://api.github.com/repos/theforeman/foreman-infra/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/theforeman/foreman-infra/downloads","issues_url":"https://api.github.com/repos/theforeman/foreman-infra/issues{/number}","pulls_url":"https://api.github.com/repos/theforeman/foreman-infra/pulls{/number}","milestones_url":"https://api.github.com/repos/theforeman/foreman-infra/milestones{/number}","notifications_url":"https://api.github.com/repos/theforeman/foreman-infra/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/theforeman/foreman-infra/labels{/name}","releases_url":"https://api.github.com/repos/theforeman/foreman-infra/releases{/id}","deployments_url":"https://api.github.com/repos/theforeman/foreman-infra/deployments","created_at":"2012-09-10T13:51:02Z","updated_at":"2018-02-21T02:10:20Z","pushed_at":"2018-02-23T13:32:39Z","git_url":"git://github.com/theforeman/foreman-infra.git","ssh_url":"git@github.com:theforeman/foreman-infra.git","clone_url":"https://github.com/theforeman/foreman-infra.git","svn_url":"https://github.com/theforeman/foreman-infra","homepage":"","size":1515,"stargazers_count":13,"watchers_count":13,"language":"HTML","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":37,"mirror_url":null,"archived":false,"open_issues_count":24,"license":null,"forks":37,"open_issues":24,"watchers":13,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/theforeman/foreman-infra/pulls/485"},"html":{"href":"https://github.com/theforeman/foreman-infra/pull/485"},"issue":{"href":"https://api.github.com/repos/theforeman/foreman-infra/issues/485"},"comments":{"href":"https://api.github.com/repos/theforeman/foreman-infra/issues/485/comments"},"review_comments":{"href":"https://api.github.com/repos/theforeman/foreman-infra/pulls/485/comments"},"review_comment":{"href":"https://api.github.com/repos/theforeman/foreman-infra/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/theforeman/foreman-infra/pulls/485/commits"},"statuses":{"href":"https://api.github.com/repos/theforeman/foreman-infra/statuses/d9c975f9cbb3620fd8f79330347c6ef35ab40d70"}},"author_association":"MEMBER"}}
{"actor":{"display_login":"ekohl"}}