Automated Documentation and Deployment for Energy Site

github repo

This repository hosts the source and deployment scripts for the energy.jnapolitano.io site, which provides detailed documentation and analysis on US power plants, natural gas infrastructure, and carbon storage facilities. It includes automated build, deployment, and backup tools to maintain the site.

Features

  • Documentation site built with Sphinx and Jupyter Notebooks
  • Automated build and deployment scripts using Makefile and Bash
  • Backup integration with Dropbox API
  • Content covering US power plants, natural gas networks, and carbon storage
  • Bibliography management for references and legal documents

Tech Stack

  • Python 3.5+ (for scripts and Sphinx extensions)
  • Jupyter Notebooks (primary language for content)
  • Sphinx documentation builder with extensions (ablog, myst_nb, sphinx_copybutton, etc.)
  • Bash scripting for deployment and maintenance
  • Dropbox SDK for Python (backup scripts)
  • Makefile for build automation

Getting Started

Prerequisites

  • Python 3.5 or higher
  • pip package manager
  • Dropbox API access token (for backup functionality)
  • Make utility

Installation

  1. Clone the repository:
git clone https://github.com/justin-napolitano/gas.jnapolitano.io.git
cd gas.jnapolitano.io
  1. Install Python dependencies:
pip install -r requirements.txt
  1. (Optional) Install dependencies for Rocky Linux:
pip install -r requirements_rocky.txt

Build the Documentation

Run the following command to clean and build the HTML documentation:

make clean
make html

Deploy the Site

Deploy the built documentation to GitHub Pages:

./deploy.sh

Backup

To back up the built HTML to Dropbox, configure the access token in backup_html.py and run:

python backup_html.py

Project Structure

acp.sh                # Bash script, purpose assumed related to access control or permissions
backup_html.py        # Python script to back up built HTML files to Dropbox
chtml.sh              # Bash script, likely for cleaning/building HTML
deploy.sh             # Bash script to deploy site to GitHub Pages
deployz.sh            # Variant deploy script
doit.sh               # General purpose automation script
install.sh            # Installation script
label_list.py         # Python script to read and print label info from Sphinx pickle files
Makefile              # Build automation for cleaning and building docs
pullit.sh             # Bash script to pull latest changes
pushit.sh             # Bash script to push commits
python_build.py       # Python build pipeline automation
requirements.txt      # Python dependencies
requirements_rocky.txt# Python dependencies for Rocky Linux
requirments.txt       # Possibly a misspelled duplicate requirements file
source/               # Sphinx documentation source files
todo/                 # Notes and TODOs
uninstall.sh          # Script to uninstall or clean environment

Future Work / Roadmap

  • Improve documentation and comments in scripts for clarity
  • Add automated testing for build and deployment processes
  • Enhance backup script with incremental backup and restore features
  • Expand content coverage on energy infrastructure
  • Refactor and unify deployment scripts for consistency
  • Correct typos in filenames (e.g., requirments.txt)
hjkl / arrows · / search · :family · :tag · :datefrom · :dateto · ~/entries/slug · Ctrl+N/Ctrl+P for suggestions · Ctrl+C/Ctrl+G to cancel
entries 201/201 · entry -/-
:readyentries 201/201 · entry -/-