Development Setup
Prerequisites
- Ruby 2.7+ (for Jekyll)
- Bundler gem
- Git
Installation
1. Clone Repository
git clone https://github.com/oyi77/oyi77.github.io.git
cd oyi77.github.io
2. Install Dependencies
This installs:
- Jekyll and GitHub Pages gems
- Jekyll plugins (paginate, sitemap, gist, feed, etc.)
- Optional: octokit, nokogiri
3. Run Local Server
Access at: http://localhost:4000/terminal/
Environment Variables (Optional)
For full functionality, set these environment variables:
export GITHUB_TOKEN=your_github_token # For GitHub data fetching
Project Structure
oyi77.github.io/
├── _data/ # Jekyll data files
├── _pages/ # Static pages
├── _posts/ # Blog posts
├── _plugins/ # Jekyll plugins
├── _layouts/ # Layout templates
├── assets/
│ ├── css/ # Stylesheets
│ ├── js/ # JavaScript
│ │ └── terminal/ # Terminal OS code
│ └── images/ # Images
└── docs/ # Documentation
Development Workflow
- Make changes to files
- Jekyll auto-rebuilds (watch mode)
- Refresh browser to see changes
- Check console for errors
Testing
Manual Testing
- Test all commands in terminal
- Verify filesystem operations
- Check theme switching
- Test responsive design
- Verify error handling
Browser Testing
Test in:
- Chrome/Edge (primary)
- Firefox
- Safari
- Mobile browsers
Troubleshooting
Jekyll Build Errors
- Check Ruby version:
ruby -v
- Update gems:
bundle update
- Clear cache:
rm -rf .jekyll-cache
Terminal Not Loading
- Check browser console for errors
- Verify xterm.js CDN links
- Check script loading order
Data Not Loading
- Verify
window.JEKYLL_DATA exists
- Check filesystem-loader.js execution
- Verify data files in
_data/
Code Style
- JavaScript: ES6+, 2 spaces, semicolons
- Ruby: 2 spaces, frozen_string_literal
- YAML: 2 spaces, consistent structure
- CSS: kebab-case, mobile-first
Git Workflow
- Create feature branch
- Make changes
- Test locally
- Commit with clear messages
- Push to GitHub
- GitHub Pages auto-deploys