Skip to content

Codeholics/codeholics

Repository files navigation

Codeholics Static Pelican Site

Codeholics.com static site generated with Pelican

Website Status UptimeRobot Monitor Github Repo Size mozilla-observatory W3C Validation libraries.io Dependencies

Clone Projects

# clone main project
git clone [email protected]:Codeholics/codeholics.git

# clone pelican plugins
git clone [email protected]:Codeholics/pelican-plugins.git

Docker Setup

If you use Docker, otherwise follow the manual process

Build Docker Image

docker-compose -f docker/docker-compose.yml build

Run Docker Container

docker-compose -f docker/docker-compose.yml up

Manual Setup

Install pip

python -m pip install

Install Venv

pip install venv

Setup Venv

You should create this under the root project folder. If you're using GitHub, make sure to exclude this directory in your gitignore file. It's also best practice to CD C:\Code\codeholics into the directory before running this command. This will create the directory C:\Code\codeholics\venvu

python -m venv C:\Code\codeholics

Activate Venvu Enviornment

`C:\Code\codeholics\venv\Scripts\Activate.ps1`

Install Python Requirements:

cd codeholics
pip install -r requirements.txt

Build Site

This step will build the site so you can view it with the dev server.

Content C:\Code\codeholics\Content is where all of your markdown documents are stored.

Output C:\Code\codeholics\output is where the final html version will be saved to.

pelican C:\Code\codeholics\Content

Run Dev Server

Start the dev server

pelican --listen # creates a server on port 8080

By default you should now see a message in the console

Server site at: http://127.0.0.1:8000


Update Site Dependencies

This will generate the requirements.txt from the requirements.in file

pip install pip-tools
pip-compile --update

Directory Structure

- codeholics
  - .github
  - content
  - docker
  - include
  - output
  - themes
  - venv

Resources