Skip to content

Instantly share code, notes, and snippets.

{"createdAt":"2018-11-07T16:19:11Z","css":[{"name":"vendor","path":"/agent/assets/vendor-70421189cb1cfd0ff188a220812505c1.css"},{"name":"application","path":"/agent/assets/application-e85e9d84b865790d32f7be2332f748b2.css"},{"name":"elements","path":"/agent/assets/elements-fb564a9a5c55cf0f2aeaa524ae8edc29.css"},{"name":"styles.css","path":"/agent/assets/lr/styles.a711c7533be25a4d.css"}],"js":[{"name":"vendor","path":"/agent/assets/vendor-8c708a93884b764415e218b433918405.js"},{"name":"application","path":"/agent/assets/application-1d12f5e6cefccc40133c75d038ee5e96.js"},{"name":"async.commons.js","path":"/agent/assets/lr/async.commons.87b5c24ced158e96.chunk.js"},{"name":"agent/assets/lr/2.2626848afe0dd538.chunk.js","path":"/agent/assets/lr/2.2626848afe0dd538.chunk.js"},{"name":"agent/assets/lr/3.9a72823b3d2b7210.chunk.js","path":"/agent/assets/lr/3.9a72823b3d2b7210.chunk.js"},{"name":"agent/assets/lr/4.64ba6869ee5282ea.chunk.js","path":"/agent/assets/lr/4.64ba6869ee5282ea.chunk.js"},{"name":"agent/assets/lr/5.1d6

ESLint Rules

I went through all of the ESLint rules and noted the ones that we might want to implement.

I did my best to make sure that there's no overlap between these rules and the ones already in the recommended sets, but some may have slipped through.

Higher Priority

Basic ESLint

@louisscruz
louisscruz / create_account
Created October 23, 2017 20:06
create_account
#!/bin/sh
COUNT_FILE=~/Code/zendesk/scripts/create_account/create_account_count.txt
create_count_file() {
echo '1' > $COUNT_FILE
}
ensure_count_file() {
if [ ! -f $COUNT_FILE ]; then
@louisscruz
louisscruz / reddit_on_rails_update.md
Last active July 13, 2017 05:55
Reddit On Rails Notes

Reddit on Rails Update

What follows are the things I had to do to update the Reddit on Rails project to Rails 5.

Create A New Project

rails new reddit_on_rails --database=postgresql
@louisscruz
louisscruz / rails_5_update.md
Last active July 13, 2017 05:54
Rails 5 Update

Upgrading Rails Projects

These instructions will step you through the process of upgrading a project from Rails 4 to Rails 5.

Before doing any of the following, ensure that you have Rails 5.1.2 installed (rails -v). If not, run gem install rails -version=5.1.2.

Let's call the existing Rails 4 project OP (Old Project), and the new Rails 5 project NP (New Project). The steps are as follows.

Workflow

@louisscruz
louisscruz / on_updating_to_rails_5.md
Created July 3, 2017 06:20
On Updating To Rails 5

On Updating To Rails 5

Hello, fellow TA. We're really glad to have you on the Rails 5 update team!

Our students are already using Rails 5, but our curriculum is not. We're going to fix that.

We'll be updating the curriculum to Rails 5.1.2. Before going on, I recommend you check that you have that specific version installed.

@louisscruz
louisscruz / update_rails.md
Last active June 30, 2017 00:54
Update Rails

Rails 5 Update Proposal

What follows is a proposal to update our curriculum projects, homework, and assessments to Rails 5.

Purpose

There are several reasons why we should update to Rails 5.

Students Are Already Using It

@louisscruz
louisscruz / channel_channel.rb
Last active February 19, 2018 04:30
ActionCable
class ChannelChannel < ApplicationCable::Channel
def subscribed
stream_from "channel_#{params[:channel_name]}"
end
end
@louisscruz
louisscruz / Gemfile
Last active October 2, 2017 16:25
Add Livereload
group :development do
gem 'guard-livereload', '~> 2.5', require: false
gem 'rack-livereload'
end