Skip to content

Commit 186fcba

Browse files
committed
no need for extra line separator or space hogging.
1 parent 494d025 commit 186fcba

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

R/github-friendly-readmes.R

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,11 +33,10 @@ append_links <- function(common = "REF_00_template.Rmd") {
3333
rdmes <- setdiff(rdmes,"README.md")
3434
splits <- lapply(strsplit(rdmes, "/", fixed = T), head, -1)
3535
splits <- lapply(splits, paste0, collapse = "/")
36-
tmp <- paste0("[",splits,"](", rdmes,")\n")
36+
tmp <- paste0("[",splits,"](", rdmes,")")
3737
parent_lines <- readLines(common)
3838
parent_links <- grepl("\\]\\(", parent_lines) #get just the link line indices
3939
stable_lines <- parent_lines[!parent_links]
40-
stable_lines <- c(stable_lines[stable_lines != ""],"")
4140
links_to_unify <- parent_lines[parent_links]
4241
all <- c(stable_lines, tmp)
4342
writeLines(all, common)

0 commit comments

Comments
 (0)