Skip to content

Commit 6e1df26

Browse files
committed
build: Override repository title
1 parent 622e2cc commit 6e1df26

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

tools/builder/prepare-gh-pages.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ const archiver = require("archiver");
88
const fg = require('fast-glob');
99

1010
const sanitize = require("./sanitze");
11+
const { title } = require("process");
1112

1213
const cwd = process.cwd();
1314

@@ -53,7 +54,8 @@ function getSteps(tutorialDir) {
5354
console.log(`👉 Copying root README.md...`);
5455
function rewriteLinks(file) {
5556
let permalink = file.split("dist/")[1].replace(".md", ".html");
56-
let content = `---\npermalink: ${permalink}\n---\n\n${readFileSync(file, { encoding: "utf8"})}`;
57+
const title = "UI5 Tutorials";
58+
let content = `---\ntitle:${title}\npermalink: ${permalink}\n---\n\n${readFileSync(file, { encoding: "utf8"})}`;
5759
content = content.replace(/README\.md/g, "index.html");
5860
content = content.replace(/\.\/packages\//g, "./");
5961
content = content.replace(/\[LICENSE\]\([\.\/\w]*\)/g, "[LICENSE](https://github.com/UI5/tutorials/blob/-/LICENSE)");

0 commit comments

Comments
 (0)