Skip to content

Commit b83c1d0

Browse files
committed
add subscribers to repo data for #23
1 parent 4ebdf20 commit b83c1d0

File tree

4 files changed

+7
-6
lines changed

4 files changed

+7
-6
lines changed

DESCRIPTION

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
Package: repometrics
22
Title: Metrics for Your Code Repository
3-
Version: 0.1.1.059
3+
Version: 0.1.1.060
44
Authors@R:
55
person("Mark", "Padgham", , "mark.padgham@email.com", role = c("aut", "cre"),
66
comment = c(ORCID = "0000-0003-2172-5265"))

R/cm-data-gh-repo.R

+1
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ repo_from_gh_api <- function (path) {
2828
homepage = null2na_char (body$homepage),
2929
size = body$size,
3030
stargazers_count = body$stargazers_count,
31+
subscribers_count = body$subscribers_count,
3132
language = null2na_char (body$language),
3233
forks_count = body$forks_count,
3334
open_issues_count = body$open_issues_count,

codemeta.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
"codeRepository": "https://github.com/ropensci-review-tools/repometrics",
99
"issueTracker": "https://github.com/ropensci-review-tools/repometrics/issues",
1010
"license": "https://spdx.org/licenses/GPL-3.0",
11-
"version": "0.1.1.059",
11+
"version": "0.1.1.060",
1212
"programmingLanguage": {
1313
"@type": "ComputerLanguage",
1414
"name": "R",

tests/testthat/test-cm-data-github.R

+4-4
Original file line numberDiff line numberDiff line change
@@ -40,16 +40,16 @@ test_that ("cm data gh repo", {
4040

4141
expect_s3_class (repo, "data.frame")
4242
expect_equal (nrow (repo), 1L)
43-
expect_equal (ncol (repo), 17L)
43+
expect_equal (ncol (repo), 18L)
4444
nms <- c (
4545
"id", "name", "full_name", "owner", "url", "description", "is_fork",
4646
"created_at", "updated_at", "homepage", "size", "stargazers_count",
47-
"language", "forks_count", "open_issues_count", "topics",
48-
"default_branch"
47+
"subscribers_count", "language", "forks_count", "open_issues_count",
48+
"topics", "default_branch"
4949
)
5050
expect_equal (names (repo), nms)
5151

52-
int_index <- c (1, 11:12, 14:15)
52+
int_index <- c (1, 11:13, 15:16)
5353
char_index <- seq_along (nms) [-int_index]
5454
int_nms <- nms [int_index]
5555
char_nms <- nms [char_index]

0 commit comments

Comments
 (0)