Skip to content

Commit

Permalink
lint
Browse files Browse the repository at this point in the history
  • Loading branch information
mpadge committed May 15, 2024
1 parent ed79b2c commit 0446211
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Package: allcontributors
Title: Acknowledge all Contributors to a Project
Version: 0.1.1.017
Version: 0.1.1.018
Authors@R:
person("Mark", "Padgham", , "[email protected]", role = c("aut", "cre"))
Description: Acknowledge all contributors to a project via a single
Expand Down
9 changes: 5 additions & 4 deletions R/add-contributors.R
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,8 @@ add_contributors <- function (repo = ".",
}))

combined_df <- do.call (rbind, all_repos [, "ctbs"])
combined_df$contributions <- stats::ave (combined_df$contributions, combined_df$login, FUN = sum)
combined_df$contributions <-
stats::ave (combined_df$contributions, combined_df$login, FUN = sum)

# Remove duplicate rows
result <- combined_df [!duplicated (combined_df [c ("logins")]), ]
Expand Down Expand Up @@ -192,7 +193,7 @@ match_type_arg <- function (type) {
"code, issues, and discussion"
))
}
c ("code", "issues", "discussion") [seq (length (type))]
c ("code", "issues", "discussion") [seq_along (type)]
}

get_org_repo <- function (repo) {
Expand Down Expand Up @@ -442,7 +443,7 @@ add_one_section <- function (ctbs, orgrepo, ncols,

if (format == "grid") {
nmax <- ceiling (nrow (ctbs) / ncols)
index <- rep (1:nmax, each = ncols) [seq (nrow (ctbs))]
index <- rep (1:nmax, each = ncols) [seq_len (nrow (ctbs))]
ctbs <- split (ctbs, as.factor (index))
} else {
ctbs <- list (ctbs)
Expand All @@ -461,7 +462,7 @@ add_one_section <- function (ctbs, orgrepo, ncols,
x <- c (x, "<tr>")
}

for (j in seq (nrow (i))) {
for (j in seq_len (nrow (i))) {
href <- NULL
u <- paste0 (
"<a href=\"https://github.com/",
Expand Down
2 changes: 0 additions & 2 deletions R/github.R
Original file line number Diff line number Diff line change
Expand Up @@ -327,8 +327,6 @@ get_gh_issue_people <- function (org, repo,
}, character (1L))
)

author <- dat$node$participants$edges

author_login <- lapply (dat, function (i) {
edges <- i$node$participants$edges
unlist (lapply (edges, function (j) j$node$login))
Expand Down
3 changes: 2 additions & 1 deletion R/urlcheck.R
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,8 @@ check_github_urls <- function (ctbs, quiet = FALSE) {
if (!quiet) {
message (
"\r", cli::col_green (cli::symbol$cross),
" Checking GitHub URLs failed; contributors will be added regardless"
" Checking GitHub URLs failed; ",
"contributors will be added regardless"
)
}
return (ctbs)
Expand Down
2 changes: 1 addition & 1 deletion codemeta.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
"codeRepository": "https://github.com/ropenscilabs/allcontributors",
"issueTracker": "https://github.com/ropenscilabs/allcontributors/issues",
"license": "https://spdx.org/licenses/GPL-3.0",
"version": "0.1.1.017",
"version": "0.1.1.018",
"programmingLanguage": {
"@type": "ComputerLanguage",
"name": "R",
Expand Down

0 comments on commit 0446211

Please sign in to comment.