Skip to content

Instantly share code, notes, and snippets.

View JuanitoFatas's full-sized avatar
🐻
Buildkite Engineering

Juanito JuanitoFatas

🐻
Buildkite Engineering
View GitHub Profile
@JuanitoFatas
JuanitoFatas / build.yml
Last active February 26, 2020 07:32
Example GitHub Actions configurations for a Rails app
# .github/workflows/build.yml
name: Build
on: [push, pull_request]
jobs:
build:
runs-on: ubuntu-latest
env:
RAILS_ENV: test
@JuanitoFatas
JuanitoFatas / rails-diff.sublime-snippet
Created April 13, 2016 07:39
Generate rails old_version..new_version diff sublime snippet
<snippet>
<content><![CDATA[
Upgrade rails from ${1:old_version} to ${2:new_version}.
- Updated: [rails](http://github.com/rails/rails), [${1:old_version}...${2:new_version}](https://github.com/rails/rails/compare/v${1:old_version}...v${2:new_version})
- Updated: actionmailer, ${1:old_version}...${2:new_version} ([CHANGELOG](https://github.com/rails/rails/blob/v${2:new_version}/actionmailer/CHANGELOG.md))
- Updated: actionpack, ${1:old_version}...${2:new_version} ([CHANGELOG](https://github.com/rails/rails/blob/v${2:new_version}/actionpack/CHANGELOG.md))
- Updated: actionview, ${1:old_version}...${2:new_version} ([CHANGELOG](https://github.com/rails/rails/blob/v${2:new_version}/actionview/CHANGELOG.md))
- Updated: activejob, ${1:old_version}...${2:new_version} ([CHANGELOG](https://github.com/rails/rails/blob/v${2:new_version}/activejob/CHANGELOG.md))
- Updated: activemodel, ${1:old_version}...${2:new_version} ([CHANGELOG](https://github.com/rails/rails/blob/v${2:new_version}/activemodel/CHANGELOG.md))
@JuanitoFatas
JuanitoFatas / .travis.yml
Last active January 7, 2016 14:08
Sample travis.yml for RubyGems.
language: ruby
bundler_args: --retry=3 --jobs=3
cache: bundler
sudo: false
rvm:
- 2.3
- 2.2
- 2.1
- 2.0
- 1.9.3

This is how we test that all translation keys match up between locales.

Stuff that only goes in one locale (such as an admin section) or that can't be translated yet (if you use external translators) can simply go in files that don't match the path "config/locales/??.yml", like "config/locales/wip.fo.yml".

@JuanitoFatas
JuanitoFatas / .zshrc
Created December 9, 2013 05:31 — forked from yorkxin/.zshrc
# Path to your oh-my-zsh configuration.
ZSH=$HOME/.oh-my-zsh
# Set name of the theme to load.
# Look in ~/.oh-my-zsh/themes/
# Optionally, if you set this to "random", it'll load a random theme each
# time that oh-my-zsh is loaded.
#ZSH_THEME="yaci"
ZSH_THEME="yaci-agnoster"
@JuanitoFatas
JuanitoFatas / as-callback.rb
Created December 1, 2013 14:58
Active Support Callbacks
require 'active_support'
class Record
include ActiveSupport::Callbacks
define_callbacks :save
def save
run_callbacks :save do
puts "save!"
end
@JuanitoFatas
JuanitoFatas / gem-update-log.md
Created October 15, 2013 02:18
Gem Update log

Gem Update log

$ gem update --system
Updating rubygems-update
Fetching: rubygems-update-2.1.9.gem (100%)
Successfully installed rubygems-update-2.1.9
Installing RubyGems 2.1.9
RubyGems 2.1.9 installed
@JuanitoFatas
JuanitoFatas / deppbot.md
Last active December 25, 2015 02:45
What is www.deppbot.com? Why bundle update?
@JuanitoFatas
JuanitoFatas / .bash_profile
Created September 28, 2013 07:05
my bash_profile
# Terminal Colour
export TERM=xterm-256color
export LSCOLORS="exfxcxdxbxegedabagacad"
export CLICOLOR=1
export LANG="zh_TW.utf-8"
export LC_ALL="zh_TW.utf-8"
# Set up Safari for development.