Skip to content

Commit 4a638d2

Browse files
committed
Build: fixed duplicate edition line in bloomr.txt
1 parent b7ce5dd commit 4a638d2

File tree

1 file changed

+10
-7
lines changed

1 file changed

+10
-7
lines changed

bloomr.build.R

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -531,7 +531,8 @@ bloomrTree <- function(){
531531

532532
bloomrTree.Core <- function(){
533533
### Make BloomR Core tree
534-
### The only difference from the Core and Bremacs edition is the name that we give to the folder tree
534+
### All editions contain Core edition files, so this function output differs only in the name given to the build folder, which is
535+
### G$branch, that is "brCore" or "brEmacs" (for non-Core editions)
535536

536537
message("\nCreating BloomR tree")
537538
desc <- if(is.core()) "BloomR Core" else "Common BloomR Lab/Studio"
@@ -598,7 +599,7 @@ bloomrTree.Core <- function(){
598599

599600

600601
## Set the edition if this is the actual Core
601-
if(is.core()){ # No if BRemacs is building the core components
602+
if(is.core()){ # No, if a BRemacs edition is building the core components
602603
edt <- paste(get.edition(), "edition")
603604
file.write(edt, app.pt("bloomr.txt"), append=TRUE)
604605
}
@@ -785,10 +786,11 @@ br-keys.el br-menico.elc br-rnw.el br-setmodes.elc ess-init.R spli
785786

786787

787788
## Set the edition if this is the actual Lab
788-
if(is.lab()){ # No if Studio is building common BRemacs
789-
ver <- file.read(app.pt("bloomr.txt"))
789+
if(is.lab()){ # No, if Studio is building common BRemacs
790+
## ver <- file.read(app.pt("bloomr.txt"))
790791
edt <- paste(get.edition(), "edition")
791-
file.write(p0(ver, "\n", edt), app.pt("bloomr.txt"))
792+
## file.write(p0(ver, "\n", edt), app.pt("bloomr.txt"))
793+
file.write(edt, app.pt("bloomr.txt"), append=TRUE)
792794
}
793795

794796
}
@@ -802,9 +804,10 @@ bloomrTree.Studio <- function(){
802804
makeStudio.addPandoc()
803805

804806
## Set the edition
805-
ver <- file.read(app.pt("bloomr.txt"))
807+
## ver <- file.read(app.pt("bloomr.txt"))
806808
edt <- paste(get.edition(), "edition")
807-
file.write(p0(ver, "\n", edt), app.pt("bloomr.txt"))
809+
## file.write(p0(ver, "\n", edt), app.pt("bloomr.txt"))
810+
file.write(edt, app.pt("bloomr.txt"), append=TRUE)
808811
}
809812

810813

0 commit comments

Comments
 (0)