mirror of
https://github.com/sascha-hemi/pycom-documentation.git
synced 2026-03-21 03:04:13 +01:00
manual rework
This commit is contained in:
54
README.md
54
README.md
@@ -1,43 +1,41 @@
|
||||
# local visualization
|
||||
# run locally
|
||||
|
||||
.md files are in the content folder, the theme forlder contains the theme.
|
||||
|
||||
install Hugo and run it on the current directory.
|
||||
```
|
||||
brew install hugo
|
||||
hugo serve
|
||||
```
|
||||
|
||||
The file config.toml contains the global .toml
|
||||
# Workflow
|
||||
|
||||
# First generation of publish branch
|
||||
- Make PR using Master branch
|
||||
- PR get merged on master
|
||||
- Then merge publish with master
|
||||
|
||||
Some commands that have been used for building:
|
||||
|
||||
- ```
|
||||
# it clone gh-pages in ./tmp/ and appy all .md files
|
||||
./reclone.sh
|
||||
# generate toc, title, redirects
|
||||
python3 migration.py
|
||||
# apply this changes to remove remaining not needed slashes protections
|
||||
rpl -R '\)' ')' *
|
||||
rpl -R '(' '(' *
|
||||
# use carrefully but there should be not .html in content
|
||||
# find "./content/" -name "*.html" -exec rm {} \;
|
||||
# then finally fix link self to images
|
||||
rpl -R "gitbook/assets/" "gitbook/assets/" *
|
||||
rpl -R "../gitbook/assets" "/gitbook/assets" content
|
||||
rpl -R "..//gitbook/assets" "/gitbook/assets" content
|
||||
rpl -R "’" "'" content
|
||||
rpl -R "✔" "✔" content
|
||||
rpl -R "(../" "(/"
|
||||
# get the images in static
|
||||
cp tmp/pydocs/gitbook/assets/* static/gitbook/assets/
|
||||
```
|
||||
git commit -m "section: commit message"
|
||||
git push origin master
|
||||
git checkout publish
|
||||
git merge master
|
||||
git push origin publish
|
||||
```
|
||||
|
||||
# some infos:
|
||||
|
||||
- assets are in ./static directory, a directory aliased at /
|
||||
- css in /themes/doc-theme/static/doc-theme.css
|
||||
- SUMMARY.md is in config.toml
|
||||
|
||||
|
||||
# help
|
||||
|
||||
- gohugo.io
|
||||
|
||||
|
||||
# detect broken links
|
||||
|
||||
```
|
||||
wget -o 404.txt -r --spider http://localhost:1313
|
||||
cat ~/output.txt | grep -B 7 404 | grep "\-\-20"
|
||||
```
|
||||
|
||||
A webhook has been installed on the publish branch to:
|
||||
- https://publish.d1rmdw1xyxqk1e.amplifyapp.com/
|
||||
|
||||
Reference in New Issue
Block a user