File tree 4 files changed +9
-33
lines changed
4 files changed +9
-33
lines changed Original file line number Diff line number Diff line change 14
14
# See the License for the specific language governing permissions and
15
15
# limitations under the License.
16
16
17
- set -e
17
+ set -xe
18
18
19
19
REQUIREMENTS=" ${GITHUB_WORKSPACE} /docs/requirements.txt"
20
20
31
31
git config --global user.name " $GITHUB_ACTOR "
32
32
git config --global user.email " $GITHUB_ACTOR @users.noreply.github.com"
33
33
34
- mkdocs build --config-file " ${GITHUB_WORKSPACE} /docs/mkdocs.yml"
34
+ docs_site_tmp_dir=$( mktemp)
35
+ cd docs && mkdocs build --config-file " ${GITHUB_WORKSPACE} /docs/mkdocs.yml" -d " ${docs_site_tmp_dir} "
35
36
36
- git clone --branch=gh-pages --depth=1 " ${remote_repo} " gh-pages
37
- cd gh-pages
37
+ gh_pages_tmp_dir=$( mktemp)
38
+
39
+ cd $gh_pages_tmp_dir
40
+ git clone --branch=gh-pages --depth=1 " ${remote_repo} " .
38
41
39
42
# copy current index file index.yaml before any change
40
43
temp_worktree=$( mktemp -d)
41
44
cp --force " index.yaml" " $temp_worktree /index.yaml"
42
45
# remove current content in branch gh-pages
43
46
git rm -r .
44
47
# copy new doc.
45
- cp -r ../site /* .
48
+ cp -r " ${docs_site_tmp_dir} " /* .
46
49
# restore chart index
47
50
cp " $temp_worktree /index.yaml" .
48
51
# commit changes
Original file line number Diff line number Diff line change 1
- .PHONY : check_dead_links
2
- check_dead_links : # # Check if the documentation contains dead links.
3
- @docker run -t \
4
- -w /tmp \
5
- -v $$ PWD:/tmp dkhamsing/awesome_bot:1.20.0 \
6
- --allow-dupe \
7
- --allow-redirect $(shell find $$PWD -mindepth 1 -name vendor -prune -o -name .modcache -prune -o -iname Changelog.md -prune -o -name "* .md" | sed -e "s#$$PWD/##")
8
-
9
1
.PHONY : build-image
10
2
build-image :
11
3
@docker build \
@@ -29,11 +21,3 @@ live-docs: build-image ## Build and launch a local copy of the documentation web
29
21
--entrypoint /bin/bash \
30
22
xpdb-docs \
31
23
-c " pip install -r /docs/requirements.txt && mkdocs serve --dev-addr=0.0.0.0:8000"
32
-
33
- .PHONY : misspell
34
- misspell : # # Check for spelling errors.
35
- @go install github.com/client9/misspell/cmd/misspell@latest
36
- misspell \
37
- -locale US \
38
- -error \
39
- .
Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -3,7 +3,7 @@ repo_name: "form3tech-oss/x-pdb"
3
3
repo_url : https://github.com/form3tech-oss/x-pdb
4
4
site_url : https://form3tech-oss.github.io/x-pdb
5
5
edit_uri : edit/main/docs/src
6
- docs_dir : " /docs/ src"
6
+ docs_dir : " src"
7
7
8
8
# Extensions
9
9
markdown_extensions :
@@ -63,8 +63,6 @@ plugins:
63
63
- minify :
64
64
minify_html : true
65
65
66
- extra_css : [extra.css]
67
-
68
66
nav :
69
67
- Introduction :
70
68
- Overview : " index.md"
You can’t perform that action at this time.
0 commit comments