Skip to content

Commit

Permalink
Update top-gh-contribs dependency
Browse files Browse the repository at this point in the history
refs TryGhost#5503

- updates package.json to using 2.0.2 version of top-gh-conribs
- updates gruntfile, using moment to calculate time period to observe
- new version of top-gh-contribs is not related to top 100 contributors therefore returns more users
- observed timepsan is reverted to 90 days now that top-gh-contribs fetches enough contributors
  • Loading branch information
cobbspur committed Jul 20, 2015
1 parent f1b558e commit 33b9343
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
6 changes: 2 additions & 4 deletions Gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -799,16 +799,14 @@ var _ = require('lodash'),
// Builds the github contributors partial template used on the Settings/About page,
// and downloads the avatar for each of the users.
// Run by any task that compiles the ember assets or manually via `grunt buildAboutPage`.
// Change which version you're working against by setting the "releaseTag" below.
//
// Only builds if the contributors template does not exist.
// To force a build regardless, supply the --force option.
// `grunt buildAboutPage --force`
grunt.registerTask('buildAboutPage', 'Compile assets for the About Ghost page', function () {
var done = this.async(),
templatePath = 'core/client/app/templates/-contributors.hbs',
imagePath = 'core/client/public/assets/img/contributors/',
timeSpan = Date.now() - (1000 * 60 * 60 * 24 * 180),
timeSpan = moment().subtract(90, 'days').format('YYYY-MM-DD'),
oauthKey = process.env.GITHUB_OAUTH_KEY;

if (fs.existsSync(templatePath) && !grunt.option('force')) {
Expand All @@ -825,7 +823,7 @@ var _ = require('lodash'),
user: 'tryghost',
repo: 'ghost',
oauthKey: oauthKey,
releaseDate: timeSpan,
sinceDate: timeSpan,
count: 18,
retry: true
})
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,6 @@
"sinon": "1.14.1",
"supertest": "1.0.1",
"testem": "0.8.3",
"top-gh-contribs": "1.0.1"
"top-gh-contribs": "2.0.2"
}
}

0 comments on commit 33b9343

Please sign in to comment.