-
Notifications
You must be signed in to change notification settings - Fork 780
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: terrytangyuan <[email protected]>
- Loading branch information
1 parent
2a05155
commit 1597aa0
Showing
3 changed files
with
35 additions
and
1 deletion.
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,5 @@ | ||
+++ | ||
title = "MPIJob" | ||
description = "Reference documentation for MPIJob" | ||
weight = 100 | ||
+++ |
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,28 @@ | ||
# Change this to where gen-crd-api-reference-docs is extracted | ||
GEN_DOCS=${HOME}/gen-crd-api-reference-docs | ||
|
||
# Change this to where the website repository is cloned. | ||
WEBSITE_ROOT=${GOPATH}/src/github.com/kubeflow/website | ||
|
||
# table style substitutions | ||
TABLE_SUB='<div class=\"table-responsive\"><table class=\"table table-bordered\">' | ||
THEAD_SUB='<thead class=\"thead-light\">' | ||
|
||
# V1alpha2 | ||
CONTENT_DIR=${WEBSITE_ROOT}/content/docs/reference/mpijob/v1alpha2 | ||
|
||
touch ${CONTENT_DIR}/mpi.md | ||
echo "+++ | ||
title = \"MPIJob\" | ||
description = \"Reference documentation for MPIJob\" | ||
weight = 100 | ||
+++" > ${CONTENT_DIR}/mpi.md | ||
|
||
touch temp_mpi.md | ||
${GEN_DOCS}/gen-crd-api-reference-docs -config ${WEBSITE_ROOT}/gen-api-reference/kubeflow-config.json -template-dir ${GEN_DOCS}/template -api-dir "github.com/kubeflow/mpi-operator/pkg/apis/kubeflow/v1alpha2" -out-file temp_mpi.md | ||
cat temp_mpi.md >> ${CONTENT_DIR}/mpi.md | ||
rm temp_mpi.md | ||
|
||
sed 's/<table>/'"$TABLE_SUB"'/g' ${CONTENT_DIR}/mpi.md > temp_mpi.md | ||
sed 's/<thead>/'"$THEAD_SUB"'/g' temp_mpi.md > ${CONTENT_DIR}/mpi.md | ||
rm temp_mpi.md |
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