Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: set default value as 7 for contributorsPerLine #139

Merged
merged 11 commits into from
Sep 7, 2022
3 changes: 2 additions & 1 deletion src/generate/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ function formatLine(contributors) {
}

function generateContributorsList(options, contributors) {
const contributorsPerLine = options.contributorsPerLine || 7
return _.flow(
_.sortBy(contributor => {
if (options.contributorsSortAlphabetically) {
Expand All @@ -53,7 +54,7 @@ function generateContributorsList(options, contributors) {
_.map(function formatEveryContributor(contributor) {
return formatContributor(options, contributor)
}),
_.chunk(options.contributorsPerLine),
_.chunk(contributorsPerLine),
_.map(formatLine),
_.join('\n </tr>\n <tr>\n '),
newContent => {
Expand Down