I’m getting stuck at something that should probably be very easy to deal with… But for some I’m not able to figure out what I need to solve it.
My system: MacOS, zsh, ruby 2.7.1p83 installed via homebrew, jekyll 4.0.0
When I run
netlify build I get the following error:
bash: jekyll: command not found
Fair enough, if I switch to bash with
exec bash and run
jekyll I get the same error. But it’s working just fine in zsh.
echo $PATH returns the same both from zsh and bash:
Can I somehow just make
netlify build use zsh, or does it need to use bash?
Some stuff I already tried:
- Adding the following to my otherwise empty
export PATH="/usr/local/opt/ruby/bin:$PATH" if which ruby >/dev/null && which gem >/dev/null; then PATH="$(ruby -r rubygems -e 'puts Gem.user_dir')/bin:$PATH" fi
- installed jekyll again using bash
gem env output:
RubyGems Environment: - RUBYGEMS VERSION: 3.1.2 - RUBY VERSION: 2.7.1 (2020-03-31 patchlevel 83) [x86_64-darwin19] - INSTALLATION DIRECTORY: /usr/local/lib/ruby/gems/2.7.0 - USER INSTALLATION DIRECTORY: /Users/tkrunning/.gem/ruby/2.7.0 - RUBY EXECUTABLE: /usr/local/opt/ruby/bin/ruby - GIT EXECUTABLE: /usr/bin/git - EXECUTABLE DIRECTORY: /usr/local/lib/ruby/gems/2.7.0/bin - SPEC CACHE DIRECTORY: /Users/tkrunning/.gem/specs - SYSTEM CONFIGURATION DIRECTORY: /usr/local/Cellar/ruby/2.7.1_2/etc - RUBYGEMS PLATFORMS: - ruby - x86_64-darwin-19 - GEM PATHS: - /usr/local/lib/ruby/gems/2.7.0 - /Users/tkrunning/.gem/ruby/2.7.0 - /usr/local/Cellar/ruby/2.7.1_2/lib/ruby/gems/2.7.0 - GEM CONFIGURATION: - :update_sources => true - :verbose => true - :backtrace => false - :bulk_threshold => 1000 - REMOTE SOURCES: - https://rubygems.org/ - SHELL PATH: - /usr/local/opt/ruby/bin - /usr/local/opt/ruby/bin - /Users/tkrunning/bin - /usr/local/bin - /usr/local/lib/ruby/bin - /usr/local/opt/ruby/bin - /usr/local/opt/ruby/bin - /Users/tkrunning/bin - /usr/local/bin - /usr/local/bin - /usr/bin - /bin - /usr/sbin - /sbin - /usr/local/opt/ruby/bin - /Users/tkrunning/bin