Create the main repo from a local directory

create_repo(
  username = Sys.getenv("git.user"),
  token = Sys.getenv("git.token"),
  repo = basename(getwd()),
  base_dir = dirname(getwd()),
  groupname = "",
  pre = "",
  ssh = FALSE,
  server = "https://gitlab.com/api/v4/"
)

Arguments

username

Username

token

Token (e.g., Sys.getenv("git.token") or Sys.getenv("GITHUB_PAT"))

repo

Name of the repo (assignment)

base_dir

Base directory for the repo. file.path(directory, assignment) should exist

groupname

Group to create on gitlab (defaults to user's namespace)

pre

Pre-amble for the repo (assignment) name

ssh

Use SSH for authentication

server

The gitlab API server

Details

See https://github.com/vnijs/gitgadget for additional documentation