2.5 KiB
2.5 KiB
title, permalink, keywords, sidebar
title | permalink | keywords | sidebar |
---|---|---|---|
Install Jekyll on Windows | /mydoc_install_jekyll_on_windows/ | jekyll on windows, pc, ruby, ruby dev kit | mydoc_sidebar |
{% comment %}
Install Chocolately
-
Go to Start and type cmd.
-
Right-click the Command Line Prompt and select Run as Administrator.
-
Copy the following code:
@powershell -NoProfile -ExecutionPolicy Bypass -Command "iex ((new-object net.webclient).DownloadString('https://chocolatey.org/install.ps1'))" && SET PATH=%PATH%;%ALLUSERSPROFILE%\chocolatey\bin
-
Right-click in the Command Line Prompt and select Paste.
-
Press Enter.
-
Close the Command Line Prompt.
Install Ruby
-
Go to Start and type cmd.
-
Right-click the Command Line Prompt and select Run as Administrator.
-
Type the following:
choco install ruby -y
-
Press Enter.
-
Close the Command Line Prompt.
{% endcomment %}
Install Ruby
- Go to RubyInstaller for Windows.
- Under RubyInstallers, download and install one of the Ruby installers (usually one of the first two options).
- Double-click the downloaded file and proceed through the wizard to install it.
Install Ruby Development Kit
- Go to RubyInstaller for Windows.
- Under the Development Kit section near the bottom, download one of the For use with Ruby 2.0 and above... options.
- Extract Ruby onto your C drive in a folder called something like RubyDevKit.
- Browse to the RubyDevKit location on your C drive using your Command Line Prompt.
- Type
ruby dk.rb init
- Type
ruby dk.rb install
If you get stuck, see the official instructions for installing Ruby Dev Kit.
Install Bundler
-
In the downloaded theme, delete the existing Gemfile and Gemfile.lock files.
-
Type
gem install bundler
. -
Browse to the documentation-jekyll-theme directory.
-
Type
bundle init
-
Open the Gemfile in a text editor.
-
Paste in the following:
# A sample Gemfile source "https://rubygems.org" gem 'wdm', '>= 0.1.0' if Gem.win_platform? gem 'jekyll', '~> 3.1', '>= 3.1.2'
-
Save and close the file.
-
Type
bundle install
.
Serve the Jekyll site
- Browse to the documentation-jekyll-theme directory.
- Type
jekyll serve
- Go to the preview address in the browser. (Make sure you include the
/
at the end.)