-
Notifications
You must be signed in to change notification settings - Fork 191
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add Windows Support for building doc (#1447)
Signed-off-by: Marinov Avgustin <[email protected]>
- Loading branch information
1 parent
0aaf973
commit 499dab3
Showing
4 changed files
with
52 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
@echo off | ||
@REM | ||
@REM Copyright (c) 2023 Bosch.IO GmbH and others | ||
@REM | ||
@REM This program and the accompanying materials are made | ||
@REM available under the terms of the Eclipse Public License 2.0 | ||
@REM which is available at https://www.eclipse.org/legal/epl-2.0/ | ||
@REM | ||
@REM SPDX-License-Identifier: EPL-2.0 | ||
@REM | ||
|
||
rem Checking for Redoc CLI and npm | ||
call npx @redocly/cli --version 1> nul 2> nul | ||
|
||
if ERRORLEVEL 1 ( | ||
echo [ERROR] Redoc CLI is not installed! Please make suer to install it before trying again. | ||
exit 1 | ||
) | ||
|
||
rem Execute the npx command | ||
call npx @redocly/cli build-docs %cd%\content\rest-api\mgmt.yaml -o %cd%\content\rest-api\mgmt.html | ||
|
||
if ERRORLEVEL 1 ( | ||
echo [ERROR] Failed to execute the Redoc CLI command form MGMT API. | ||
exit 1 | ||
) else ( | ||
echo [INFO] Successfully executed the Redoc CLI command for MGMT API. | ||
) | ||
|
||
rem Execute the npx command | ||
call npx @redocly/cli build-docs %cd%\content\rest-api\ddi.yaml -o %cd%\content\rest-api\ddi.html | ||
|
||
if ERRORLEVEL 1 ( | ||
echo [ERROR] Failed to execute the Redoc CLI command form DDI API. | ||
exit 1 | ||
) else ( | ||
echo [INFO] Successfully executed the Redoc CLI command for DDI API. | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters