aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Holmes <mike.holmes@linaro.org>2017-07-10 14:29:08 -0400
committerMike Holmes <mike.holmes@linaro.org>2017-07-10 14:29:08 -0400
commit83891cee5776a6b2bdb6faef7045f489560856d1 (patch)
tree6cd0d8f6d425b9741d08454dfde5acc19a9294d6
parent97ccd0710e5f33dce874d954312b84d1b4ce3f85 (diff)
Take an output dir form the env
-rw-r--r--Signed_off_heatmaps.R12
1 files changed, 8 insertions, 4 deletions
diff --git a/Signed_off_heatmaps.R b/Signed_off_heatmaps.R
index b549cce..269a97b 100644
--- a/Signed_off_heatmaps.R
+++ b/Signed_off_heatmaps.R
@@ -108,7 +108,7 @@ get_projects <- function (df){
colours <- c("lightblue", "mistyrose", "lightcyan","lavender", "cornsilk")
#from the website get the initiatives list for the four teams
-id <- Sys.getenv(c("JIRA_USERNAME", "JIRA_PASSWORD"))
+id <- Sys.getenv(c("JIRA_USERNAME", "JIRA_PASSWORD","JIRA_OUTPUT"))
if (id[1] == '') {
print ("export JIRA_USERNAME='john.doe@linaro.org'")
@@ -119,10 +119,14 @@ if (id[2] == '') {
stop()
}
-home <- getwd()
-print(paste("Outputdir = ", home))
-user_password <- paste(id[1], id[2], sep=":")
+if (id[3] == '') {
+ home <- getwd()
+ print(paste("Outputdir = ", home))
+} else {
+ home <- id[3]
+}
+user_password <- paste(id[1], id[2], sep=":")
h <- new_handle(failonerror = TRUE)
handle_setopt(h, verbose = 0)