File tree Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Original file line number Diff line number Diff line change @@ -8,8 +8,10 @@ schemaDir="src/schemas/validation"
8
8
branch=$( git branch --show-current)
9
9
10
10
if [[ $branch =~ ^v([0-9]+\. [0-9]+\. [0-9]+) ]]; then
11
- deploydir=" ./deploy/oas/${BASH_REMATCH[1]} "
11
+ version=${BASH_REMATCH[1]}
12
+ deploydir=" ./deploy/oas/${version} "
12
13
else
14
+ version=" "
13
15
deploydir=" ./deploy-preview"
14
16
fi
15
17
@@ -21,6 +23,7 @@ publish_schema() {
21
23
22
24
local base=$( basename $schema ' .yaml' )
23
25
local target=$deploydir /$base /$date
26
+ local jekyllLander=$base /$version .md
24
27
25
28
mkdir -p $deploydir /$base
26
29
# replace the WORK-IN-PROGRESS placeholders
@@ -29,6 +32,13 @@ publish_schema() {
29
32
node scripts/yaml2json/yaml2json.js " $target .yaml"
30
33
rm " $target .yaml"
31
34
mv " $target .json" " $target "
35
+
36
+ # Move the jekyll lander markdown for this iteration to the deploy destination.
37
+ # The lander files only exist in the gh-pages branch.
38
+ if [ -f " $jekyllLander " ]; then
39
+ mv $jekyllLander $target .md
40
+ fi
41
+
32
42
echo " * $newestCommitDate : $schema "
33
43
}
34
44
You can’t perform that action at this time.
0 commit comments