Skip to content

Commit f3b40a7

Browse files
committed
Add link to Travis build
1 parent fec9743 commit f3b40a7

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

inst/testscripts/comment.R

+3-2
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,8 @@ system("git add index.html")
4747
system("git add tables/*/*.html")
4848
system("git add data/*/*.png")
4949
system("git add data/*/*.log")
50-
commit_msg <- paste0('"Pushed from https://travis-ci.org/ropensci/plotly/builds/"', a[2])
50+
build_link <- paste0('https://travis-ci.org/ropensci/plotly/builds/', a[2])
51+
commit_msg <- paste0('"Pushed from ', build_link, '"')
5152
system(paste('git commit -m', commit_msg))
5253
# This post explains how this works -- http://rmflight.github.io/posts/2014/11/travis_ci_gh_pages.html
5354
repo <- sprintf("https://%[email protected]/ropensci/plotly-test-table.git", a[4])
@@ -59,7 +60,7 @@ system(paste("git push -q", repo, "gh-pages"))
5960
tbl_link <- sprintf("http://ropensci.github.io/plotly-test-table/tables/%s/index.html", a[3])
6061
msg <- sprintf("On TravisCI, commit %s was successfully merged with %s (master) to create %s. A visual testing table comparing %s with %s can be found here:\n %s",
6162
info$head$sha, info$base$sha, a[3], info$base$sha, a[3], tbl_link)
62-
msg <- paste("> The message below was automatically generated \n\n", msg)
63+
msg <- paste("> The message below was automatically generated after build", build_link, "\n\n", msg)
6364
commentz <- sprintf(paste0(base, 'issues/%s/comments'), a[1])
6465
res <- GET(commentz, header)
6566
warn_for_status(res)

0 commit comments

Comments
 (0)