X157 Dev Notes

One simulant attempts to share insight with others.

Development Setup

There are three supported ways to test the site:

  1. Windows + WSL (Current)
  2. Any + Docker (Planned)
  3. Local (Planned)

1. Windows + WSL

Prerequisites

We recommend using WSL (Windows Subsystem for Linux) for the best compatibility with Jekyll on Windows.

1. Verification

Ensure WSL is installed (PowerShell):

wsl --version

2. Install Ruby & Jekyll (using WSL)

  1. Check if already installed:
     wsl bash -ic 'gem list jekyll'
    
  2. Update & Install Ruby:
    wsl -u root bash -ic 'apt update'
    wsl -u root bash -ic 'apt install ruby-full build-essential zlib1g-dev'
    
  3. Configure Gem Path (avoids using sudo for gems):
    $foundSetup = wsl bash -ic "grep '# Install Ruby Gems to ~/gems' ~/.bashrc | wc -l"
    if ($foundSetup -eq 0) {
        echo '# Install Ruby Gems to ~/gems' | wsl bash -ic 'tee -a ~/.bashrc'
        echo 'export GEM_HOME="~/gems"' | wsl bash -ic 'tee -a ~/.bashrc'
        echo 'export PATH="~/gems/bin:$PATH"' | wsl bash -ic 'tee -a ~/.bashrc'
    }
    
  4. Install Jekyll & Bundler:
    wsl bash -ic 'gem install jekyll bundler'
    

Running

  1. Install Dependencies: Open PowerShell in the project directory:
    wsl bash -ic 'bundle install'
    
  2. Start Server: This command will NOT exit until the server is stopped. To stop the server, press Ctrl+C.
    wsl bash -ic 'bundle exec jekyll serve --livereload'
    
  3. View Site: Open http://localhost:4000 in your Windows browser.

2. Any + Docker

Details coming soon.

3. Local

Details coming soon.