Skip to content

Commit

Permalink
build(release): compiled action for 1.1.0
Browse files Browse the repository at this point in the history
[skip ci]
  • Loading branch information
semantic-release-bot committed Aug 20, 2020
1 parent 1cf7b55 commit d17a1ed
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions dist/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -282,13 +282,15 @@ async function main() {
try {
const {
installations,
repositories,
popularRepositories,
suspendedInstallations,
} = await getAppStats({
id,
privateKey,
});
core.setOutput("installations", installations);
core.setOutput("repositories", repositories);
core.setOutput("popular_repositories", JSON.stringify(popularRepositories));
core.setOutput("suspended_installations", suspendedInstallations);
console.log("done.");
Expand Down Expand Up @@ -9606,6 +9608,7 @@ async function getAppStats({ id, privateKey }) {
);

const accounts = [];
let installedRepositories = 0;
let suspendedInstallations = 0;
for (const installation of installations) {
if (installation.suspended) {
Expand Down Expand Up @@ -9643,11 +9646,13 @@ async function getAppStats({ id, privateKey }) {
}, 0);

accounts.push({ ...installation, stars });
installedRepositories += repositories.length;
}

console.log("");
return {
installations: accounts.length + suspendedInstallations,
repositories: installedRepositories,
suspendedInstallations,
popularRepositories: accounts
.sort((a, b) => b.stars - a.stars)
Expand Down

0 comments on commit d17a1ed

Please sign in to comment.