How to edit the lessons in this webpage:
Edit these lessons on GitHub
If you can't fix an error or make an addition right now, file an issue with the doc that needs changing. Each doc (shows up as a tab or page on the website) is stored as a .md document within the doc folder.
Creating a pull request:
git clone https://github.com/dib-lab/dib_rotation.gitto clone the repo on to you computer- from inside that repo, make yourself a branch to work on:
git checkout -b my-awesome-branch - make some changes in the markdown on your branch
git add changed_file.mdfor each file you changegit committo save changes
- When you're satisfied with your changes, open a pull request to integrate these changes into the main branch:
git push --set-upstream origin my-awesome-branchgit pushto upload updated files (all changes up to last commit)- when you open GitHub again in a browser, it will prompt you to open a pull request
- if you are correcting a filed issue, it's helpful to tag the issue number in the pull request (e.g.
fixes issue #1234)
- if you are correcting a filed issue, it's helpful to tag the issue number in the pull request (e.g.
- When integrated, your changes will automatically render on the training website.
Add a new page (markdown document):
- put the
.mdfile in thedocfolder - add the title and file name to
mkdocs.yml- under the
navsection, formatted with the name and title like the other docs are - this allows a tab to render for your doc in the side bar on the webpage
- place it in the list in the place you want it to appear on the webpage
- under the
View the updated rendered website locally:
- make a conda env
mamba create -n mkdocs mkdocs- if you dont have mamba, use
mamba create -n mkdocs mkdocs
- if you dont have mamba, use
- activate that environment:
conda activate mkdocs pip install mkdocs-materialto install the "material" theme
cdto the repo (dib_rotation, or wherevermkdocs.ymlis sitting)- build the docs into a website:
mkdocs build - serves the site to a local webserver:
mkdocs serve - a browser window might open automatically,
- this may not work if you are using
wsl - the address should also be visible on the terminal output if you need to input it manually.
- the URL is short, looks something like
http://123.0.0.1:4000/
- the URL is short, looks something like
- this may not work if you are using