Skip to content

Instantly share code, notes, and snippets.

@newbrunomartins
Last active January 31, 2021 13:36
Show Gist options
  • Save newbrunomartins/9a0be622df93c9da64a278adc25d2702 to your computer and use it in GitHub Desktop.
Save newbrunomartins/9a0be622df93c9da64a278adc25d2702 to your computer and use it in GitHub Desktop.
Instalação de Rails descomplicada no Antergos/Arch Linux
#Instalando as dependências do Rails:
sudo pacman -S nodejs
#Instalando o Ruby
sudo pacman -S ruby
#Permitindo o Ruby on Rails em qualquer versão (Em algumas instalações deu erro e isto corrigiu o caminho)
nano ~/.bashrc
if which ruby >/dev/null && which gem >/dev/null; then
PATH="$(ruby -rubygems -e 'puts Gem.user_dir')/bin:$PATH"
fi
#Execultando o comando anterior
exec $SHELL
#instalando o Rails
gem install rails --no-document
#Atualizando as Gems
gem update
#Estes passos abaixo resolvem os erros de "Spring" na hora de rodar o servidor ou novos servidores (# rails server).
#LEMBRE DE ENTRAR DENTRO DO APP PARA CONTINUAR!!
bundle install --path .bundle
bundle exec rake rails:update:bin
# O sistema irá informar um conflito em bin/rails e dar uma opção, escolha "Y"
# Novamente, mas agora em bin/rake. Novamente "Y"
#Rode o servidor e seja feliz ;)
Copy link

ghost commented Oct 31, 2017

No meu deu esse erro:
-e:1:in <main>': undefined local variable or method home' for main:Object (NameError)

@newbrunomartins
Copy link
Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment