Installation
How to start crafting documentation with LibDoc.
Online - Remote theme
Available only on GitHub, remote theme feature is the most simple way to use LibDoc, it does not require any installation, just follow these few steps:
- Create a repository
Just add a new repository on your GitHub account. Example - Create a LibDoc config file
Create and configure your LibDoc config file called _config.yml, required for GitHub Pages, do not forget to add/uncomment the following line:remote_theme: olivier3lanc/Jekyll-LibDoc
View a _config.yml example - Enable Github Pages
To automatically compile your LibDoc project, just enable GitHub Pages athttps://github.com/[GH_USER_NAME]/[REPO_NAME]/settings/pages
. Each time you commit and push on the specified branch, Github Pages builds and hosts your project on the URLhttps://[GH_USER_NAME].github.io/[REPO_NAME]
.
Your repository is now ready to be deployed as GitHub Pages website, all you have to do is adding your content! Learn more about remote themes
Online - Copy or clone
It is possible to craft documentation with LibDoc only with your browser, Github and Github Pages.
- Copy, clone or fork LibDoc repository
- On the forked/copy repository, press
Shift + .
or go tohttps://github.dev/[GH_USER_NAME]/[REPO_NAME]/tree/[BRANCH_NAME]
- You are now into Visual Studio Code and you can edit, commit and push.
To automatically compile your LibDoc project, just enable your instance on this page https://github.com/[GH_USER_NAME]/[REPO_NAME]/settings/pages
. Each time you commit and push on the specified branch, Github Pages builds and hosts your project on the URL https://[GH_USER_NAME].github.io/[REPO_NAME]
.
Locally
LibDoc requires only Jekyll to compile your work.
- Install Jekyll on your machine following the steps described here
- Get the latest version of LibDoc
- Download blank or Download with demo content
- You can also clone repository from your terminal
git clone git@github.com:olivier3lanc/Jekyll-LibDoc.git
- Into the folder where LibDoc was copied, adjust your settings of your YAML file, Most important are
url
The host of your local set up, this can be for example http://localhost or http://192.168.1.2 or domaine namebaseurl
The path to your local copy of LibDoc. For example /Jekyll-LibDoc/_sitetitle
Title of the documentationdescription
Description of your documentation project
- Compile your project using:
jekyll build
Builds the project using _config.ymljekyll build -c _personal-config.yml
Builds the project using _personal-config.ymljekyll build -c _personal-config.yml --watch
Builds the project using _personal-config.yml and automatically compiles on detected changes.- Learn more about command line usage on official Jekyll documentation
Local with remote theme
It is possible to only write your content without complete LibDoc installation, just use LibDoc as remote theme. You only need to use locally Jekyll remote theme plugin
- Install Jekyll on your machine following the steps described here
- Add a Gemfile with the following line
gem "jekyll-remote-theme"
and run
bundle install
to install the plugin -
Add the following to your LibDoc’s local config file _config-local.yml
remote_theme: olivier3lanc/Jekyll-LibDoc plugins: - jekyll-remote-theme
- Run
jekyll build
or with any custom config filejekyll build -c _your-own-config.yml
Feel free to use the example repository as starter template.