Skip to content

Instantly share code, notes, and snippets.

View rubyandcoffee's full-sized avatar
🐒

Alexandra Wolfe rubyandcoffee

🐒
  • Cheshire, United Kingdom
View GitHub Profile
@rubyandcoffee
rubyandcoffee / terminal
Last active May 22, 2022 16:22
Error: Rails is not currently installed on this system.
If you're receiving the following error:
Rails is not currently installed on this system.
Then you're probably on a Ruby version which doesn't have Rails installed.
To fix, switch to a Ruby version which does have Rails installed.
If you've tried to install Rails, and you're receiving a PERMISSIONS error,
then you're probably using the default system-installed Ruby, instead of the Ruby version manager-installed version (e.g. installed using ruby-install).
@rubyandcoffee
rubyandcoffee / Ruby with chruby
Last active February 23, 2024 11:34
chruby - Installing and managing Ruby versions
To install chruby and ruby-install:
brew install chruby ruby-install
To install Ruby using ruby-install:
ruby-install ruby 2.7.1
NOTE: You can find latest stable version of Ruby here: https://www.ruby-lang.org/en/downloads/
If you have issues installing Ruby then try the following:
brew install openssl@3
ruby-install 3.2.2 -- --with-openssl-dir=$(brew --prefix openssl@3)
require 'rails_helper'
RSpec.describe TodosController, :type => :controller do
describe "GET #index" do
#describe "POST #create" do
#describe "GET #show" do
#describe "PATCH #update" do (or PUT #update)
#describe "DELETE #destroy" do
#describe "GET #new" do
@subelsky
subelsky / aliases.sh
Created October 17, 2013 14:05
Useful aliases for Ruby and Rails development and git maintenance
alias a='ack'
alias a?='alias | grep -i'
alias adx='rake db:drop && rake db:create && heroku pg:transfer --from black --to postgres://postgres@localhost/staq_development --confirm staqweb --app staqweb && rails r "User.all.each { |u| u.update_attribute(:password,%q(password)) }" && rake db:test:prepare'
alias b='bundle'
alias bb='bundle install --binstubs=.bundle/bin --path=.bundle/gems && bundle package --all && reload ; sd'
alias bc='bin/console'
alias be='bundle exec'
alias bea='bundle exec annotate'
alias bu='bundle update'
alias bus='bundle update staq_extraction'