You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+15Lines changed: 15 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -26,14 +26,29 @@ When you are initially working your website, it is very useful to be able to pre
26
26
```bash
27
27
sudo apt install ruby-dev ruby-bundler nodejs
28
28
```
29
+
If you see error `Unable to locate package ruby-bundler`, `Unable to locate package nodejs `, run the following:
30
+
```bash
31
+
sudo apt update && sudo apt upgrade -y
32
+
```
33
+
then try run `sudo apt install ruby-dev ruby-bundler nodejs` again.
34
+
29
35
On MacOS the commands are:
30
36
```bash
31
37
brew install ruby
32
38
brew install node
33
39
gem install bundler
34
40
```
35
41
1. Run `bundle install` to install ruby dependencies. If you get errors, delete Gemfile.lock and try again.
42
+
43
+
If you see file permission error like `Fetching bundler-2.6.3.gem ERROR: While executing gem (Gem::FilePermissionError) You don't have write permissions for the /var/lib/gems/3.2.0 directory.` or `Bundler::PermissionError: There was an error while trying to write to /usr/local/bin.`
44
+
Install Gems Locally (Recommended):
45
+
```bash
46
+
bundle config set --local path 'vendor/bundle'
47
+
```
48
+
then try run `bundle install` again. If succeeded, you should see a folder called `vendor` and open `.gitignore` then add `vendor` inside it.
49
+
36
50
1. Run `jekyll serve -l -H localhost` to generate the HTML and serve it from `localhost:4000` the local server will automatically rebuild and refresh the pages on change.
51
+
You may also try `bundle exec jekyll serve -l -H localhost` to ensure jekyll to use specific dependencies on your own local machine.
37
52
38
53
If you are running on Linux it may be necessary to install some additional dependencies prior to being able to run locally: `sudo apt install build-essential gcc make`
0 commit comments