Skip to content

Commit e433af8

Browse files
committed
Add support for allRepos tag
Takes a user/github-user-name or an orgs/github-org-name value, and takes all the respositories there.
1 parent 01eacf1 commit e433af8

File tree

2 files changed

+19
-0
lines changed

2 files changed

+19
-0
lines changed

README.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,16 @@ The set of mailing lists, repos / TR documents and events is configured in a JSO
4242
]
4343
}
4444
]
45+
},
46+
47+
"digest:tuesday": [
48+
{
49+
"allRepos": "users/githubaccount"
50+
}
51+
{
52+
"allRepos": "orgs/orgname"
53+
}
54+
]
4555
}
4656
}
4757
```

index.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -275,6 +275,15 @@ def getRepoList(source):
275275
repos = []
276276
if ("repos" in source):
277277
repos = source["repos"]
278+
if ("allRepos" in source):
279+
try:
280+
url = "https://github.com/" + source["allRepos"] + "/repos"
281+
repolist = requests.get(url).json()
282+
repolist = [x.name for x in repolist]
283+
repos = uniq(repos + repolist)
284+
except pass:
285+
# TODO: Bad URL, report error?
286+
278287
if ("repoList" in source):
279288
try:
280289
repolist = requests.get(source["repoList"]).json()

0 commit comments

Comments
 (0)