Skip to content

Commit

Permalink
Merge pull request #55 from ropensci-review-tools/token
Browse files Browse the repository at this point in the history
feat: use gitcreds that will fall back to the environment variable
  • Loading branch information
mpadge authored Apr 19, 2024
2 parents 02a7645 + 8b139c8 commit 7e494ff
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ Imports:
fs,
gert,
ghql,
gitcreds,
here,
httr,
jsonlite,
Expand Down
2 changes: 1 addition & 1 deletion R/utils.R
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ symbol_crs <- function () {
#' @noRd
get_github_user <- function () {

gh_tok <- Sys.getenv ("GITHUB_TOKEN")
gh_tok <- gitcreds::gitcreds_get ()$password

# Check corresponding user name:
u <- "https://api.github.com/user"
Expand Down

0 comments on commit 7e494ff

Please sign in to comment.