Skip to content

Commit 654b049

Browse files
committed
devtools::document() and rebuild!
1 parent 093c6a8 commit 654b049

File tree

5 files changed

+65
-11
lines changed

5 files changed

+65
-11
lines changed

NAMESPACE

+2
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,14 @@ export(create_repo_map)
88
export(deploy_app)
99
export(deploy_website)
1010
export(extract_global_region)
11+
export(extract_mazu_by_rgn)
1112
export(gh_remote_branches)
1213
export(populate_conf)
1314
export(populate_etc)
1415
export(populate_init)
1516
export(populate_layers)
1617
export(populate_prep)
18+
export(shp_to_geojson)
1719
export(unpopulate_layers_conf)
1820
import(brew)
1921
import(devtools)

R/populate_init.r

+12-10
Original file line numberDiff line numberDiff line change
@@ -32,20 +32,21 @@ populate_init <- function(repo_registry,
3232
# Error in 'git2r_clone': Unable to authenticate with supplied credentials
3333
}
3434

35+
## commenting out; not sure we need this anymore if we be sure it's created
3536
## get remote branches
36-
remote_branches <- sapply(git2r::branches(repo, 'remote'), function(x) stringr::str_split(x@name, '/')[[1]][2])
37+
# remote_branches <- sapply(git2r::branches(repo, 'remote'), function(x) stringr::str_split(x@name, '/')[[1]][2])
3738
## try one day with purrr
3839

3940
## initialize repo
40-
if (length(remote_branches)==0){
41-
system('touch README.md')
42-
system('git add -A; git commit -m "first commit"')
43-
try(system('git remote rm origin')) # stackoverflow.com/questions/1221840/remote-origin-already-exists-on-git-push-to-new-repository
44-
system(sprintf('git remote add origin https://github.com/OHI-Science/%s.git', key))
45-
system('git push -u origin master')
46-
system('git pull')
47-
remote_branches = sapply(branches(repo, 'remote'), function(x) str_split(x@name, '/')[[1]][2])
48-
}
41+
# if (length(remote_branches)==0){
42+
# system('touch README.md')
43+
# system('git add -A; git commit -m "first commit"')
44+
# try(system('git remote rm origin')) # stackoverflow.com/questions/1221840/remote-origin-already-exists-on-git-push-to-new-repository
45+
# system(sprintf('git remote add origin https://github.com/OHI-Science/%s.git', key))
46+
# system('git push -u origin master')
47+
# system('git pull')
48+
# remote_branches = sapply(branches(repo, 'remote'), function(x) str_split(x@name, '/')[[1]][2])
49+
# }
4950

5051
## recreate empty dir, except hidden .git (all.files=FALSE)
5152
for (f in list.files(dir_repo, all.files=FALSE)) {
@@ -71,6 +72,7 @@ populate_init <- function(repo_registry,
7172
cat(sprintf("git add, commit, and push %s repo", key))
7273
system(sprintf('cd %s; git add -A; git commit -a -m "%s repo populated with initial files"', dir_repo, key))
7374
system(sprintf('cd %s; git push origin master', dir_repo))
75+
7476
}
7577

7678
return(repo)

man/clone_repo.Rd

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

man/extract_mazu_by_rgn.Rd

+26
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

man/shp_to_geojson.Rd

+24
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)