Skip to content

Commit 5e15cef

Browse files
Merge pull request #4953 from NativeScript/etabakov/fix-improvethis
fix: "improve this" btn doesn't work for CLI docs
2 parents 83b9c34 + 50b111a commit 5e15cef

File tree

5 files changed

+5
-6
lines changed

5 files changed

+5
-6
lines changed

docs/build-jekyll-md.sh

-4
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,3 @@ rm -rf docs-cli
55
npm install --ignore-scripts
66

77
grunt docs-jekyll
8-
if [ -d docs-cli ]; then
9-
cd docs-cli
10-
mv index.md start.md
11-
fi

docs/man_pages/index.html

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
<script type="text/javascript">
2+
window.location = 'start.html';
3+
</script>
File renamed without changes.

lib/common/services/help-service.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -195,7 +195,7 @@ export class HelpService implements IHelpService {
195195
await this.throwMissingCommandError(commandData);
196196
}
197197

198-
return (commandName && commandName.replace(/\|/g, "-")) || "index";
198+
return (commandName && commandName.replace(/\|/g, "-")) || "start";
199199
}
200200

201201
private async throwMissingCommandError(commandData: ICommandData): Promise<void> {

lib/common/test/unit-tests/services/help-service.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -422,7 +422,7 @@ and another one`
422422
it("shows index help when command is not specified", async () => {
423423
const injector = createTestInjector();
424424
injector.register("fs", {
425-
enumerateFilesInDirectorySync: (path: string) => ["index.md"],
425+
enumerateFilesInDirectorySync: (path: string) => ["start.md"],
426426
readText: () => "index data is read"
427427
});
428428

0 commit comments

Comments
 (0)