Skip to content

Commit 489dbc3

Browse files
committed
Add theobromine tutorial
1 parent cb14071 commit 489dbc3

3 files changed

Lines changed: 451 additions & 3 deletions

File tree

‎README.md‎

Lines changed: 34 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -88,13 +88,45 @@ This uses the Gemfile in the repository to install:
8888
- and any other required gems.
8989

9090

91-
### 5. Serve the site locally
91+
### 5. Serve the site locally (macOS)
92+
93+
### Why this setup
94+
macOS ships with a locked “system Ruby” that often causes permission errors when installing gems.
95+
To avoid this, use Homebrew Ruby and install gems locally in the repo.
96+
97+
98+
#### 1 Install Ruby via Homebrew
99+
```bash
100+
brew install ruby
101+
```
102+
103+
##### 2 Ensure Homebrew Ruby is used (IMPORTANT)
104+
```bash
105+
echo 'export PATH="$(brew --prefix ruby)/bin:$PATH"' >> ~/.zshrc
106+
source ~/.zshrc
107+
108+
which ruby
109+
ruby -v
92110
```
111+
112+
If which ruby prints /usr/bin/ruby, you are still using system Ruby — fix your PATH before continuing.
113+
114+
#### 3 Install Bundler and dependencies (local install)
115+
```bash
116+
gem install bundler
117+
118+
bundle config set --local path vendor/bundle
119+
bundle install
120+
```
121+
122+
#### 4 Run the site locally
123+
124+
```bash
93125
bundle exec jekyll serve --port 4001
94126
```
95127

96128
Jekyll will print something like:
97-
```
129+
```bash
98130
Server address: http://127.0.0.1:4001/
99131
Server running... press ctrl-c to stop.
100132
```

0 commit comments

Comments
 (0)