-
Update the system:
sudo apt update sudo apt upgrade
-
Install Ruby and dependencies:
sudo apt install ruby-full build-essential zlib1g-dev
-
Set up Ruby Gems environment:
echo '# Install Ruby Gems to ~/gems' >> ~/.bashrc echo 'export GEM_HOME="$HOME/gems"' >> ~/.bashrc echo 'export PATH="$HOME/gems/bin:$PATH"' >> ~/.bashrc source ~/.bashrc
-
Install Jekyll and Bundler:
gem install jekyll bundler
-
Create a new Jekyll site:
jekyll new my-awesome-site cd my-awesome-site
-
Build and serve your site locally:
bundle exec jekyll serve
- Access your site at
http://localhost:4000
.
- Access your site at
-
Install Git:
sudo apt install git
-
Configure Git:
git config --global user.name "Your Name" git config --global user.email "[email protected]"
-
Create a GitHub repository:
- Name it
username.github.io
(replaceusername
with your GitHub username).
- Name it
-
Initialize and push your site:
git init git add . git commit -m "Initial commit" git branch -M main git remote add origin https://github.com/username/username.github.io.git git push -u origin main
-
Configure
_config.yml
:url: "https://username.github.io"
-
Push changes:
git add . git commit -m "Configure for GitHub Pages" git push
-
Enable GitHub Pages:
- Go to your repository on GitHub, navigate to Settings > Pages, select the main branch, and click Save.
Your site is now live at https://username.github.io
. Push changes to the main branch to update your site.
bundle install
jekyll build
bundle exec jekyll serve --livereload