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

Fixed case-sensitivity of repo names #120

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions lib/dashboards.js
Original file line number Diff line number Diff line change
Expand Up @@ -172,8 +172,8 @@ function assembleDashboard(options) {
} else {
return reject(NICE_ERRORS.UNEXPECTED_LIMIT_TYPE(options.limit));
}
const outputFile = path.join(options.userConfig.output_directory, outputSlug);
const outputFileRedirect = path.join(options.userConfig.output_directory, outputSlugRedirect);
const outputFile = path.join(options.userConfig.output_directory, outputSlug.toLowerCase());
const outputFileRedirect = path.join(options.userConfig.output_directory, outputSlugRedirect.toLowerCase());
const outputDir = path.dirname(outputFile);
let tmplvars = {
widgets: options.htmls,
Expand Down Expand Up @@ -209,8 +209,8 @@ function assembleDashboard(options) {
}
if (writeRedirect) {
var redirectParams = {
outputSlugAll: path.basename(includeExcludeOrgFilenames[0]),
outputSlugExcludeOrg: path.basename(includeExcludeOrgFilenames[1])
outputSlugAll: path.basename(includeExcludeOrgFilenames[0]).toLowerCase(),
outputSlugExcludeOrg: path.basename(includeExcludeOrgFilenames[1]).toLowerCase()
};
options.templates.redirect(redirectParams, (err, output) => {
fs.writeFile(outputFileRedirect, output, {encoding: "utf8"}, err => {
Expand Down Expand Up @@ -508,4 +508,4 @@ module.exports = {
dashboardForEachRepo: dashboardForEachRepo,
dashboardForEachTeam: dashboardForEachTeam,
runWidgets: runWidgets
}
}
3 changes: 2 additions & 1 deletion lib/pages.js
Original file line number Diff line number Diff line change
Expand Up @@ -216,7 +216,7 @@ function writeFront(options, links, orgs) {
if (err) {
return reject(NICE_ERRORS.COULD_NOT_WRITE_OUTPUT(err, outputFile));
}
options.templates.redirect({outputSlugAll:path.basename(outputSlugAll), outputSlugExcludeOrg:path.basename(outputSlugExcludeOrg)}, (err, output) => {
options.templates.redirect({outputSlugAll:path.basename(outputSlugAll).toLowerCase(), outputSlugExcludeOrg:path.basename(outputSlugExcludeOrg).toLowerCase()}, (err, output) => {
fs.writeFile(outputFileRedirect, output, {encoding: "utf8"}, err => {
if (err) {
return reject(NICE_ERRORS.COULD_NOT_WRITE_OUTPUT(err, outputFile));
Expand Down Expand Up @@ -356,3 +356,4 @@ module.exports = {
searchPage: searchPage,
calculateCodeHash: calculateCodeHash
}