Skip to content

Instantly share code, notes, and snippets.

@strawberryjello
strawberryjello / .rubocop-zen-old.yml
Last active August 29, 2015 14:20
Sample annotated Rubocop YAML file
# GENERAL
# Indent using soft indents (2 whitespace) instead of real tab.
# Enabled by default
# Style/IndentationWidth
# Limit lines to 80 characters except for HAML files.
# Enabled by default
# Metrics/LineLength
@strawberryjello
strawberryjello / cops-rubocop-0-32-1.yml
Created July 31, 2015 11:14
Sample YAML file containing all Rubocop cops (Rubocop 0.32.1)
# Available cops (226):
# Type 'Lint' (41):
Lint/AmbiguousOperator:
Description: Checks for ambiguous operators in the first argument of a method invocation
without parentheses.
StyleGuide: https://github.com/bbatsov/ruby-style-guide#parens-as-args
Enabled: true
Lint/AmbiguousRegexpLiteral:
Description: Checks for ambiguous regexp literals in the first argument of a method
@strawberryjello
strawberryjello / .rubocop-zen.yml
Last active November 3, 2017 18:49
Sample annotated Rubocop YAML file (Rubocop 0.32.1)
# Last updated: 3 August 2015
#
# Applicable for Rubocop 0.32.1
#
# This document contains a custom Rubocop ruleset adhering to the Clinic-IT Ruby Style Guide (https://github.com/clinic-it/zen/blob/master/guidelines/ruby.md).
#
# All rules from the above are listed, with notes about whether they:
# - are enabled by default
# - require configuration
# - have not been implemented
@strawberryjello
strawberryjello / postgresql-cleanup.sh
Created June 15, 2016 08:00
Cleaning up PostgreSQL PID file and restarting the server after it crashes because of OS X updates
#! /bin/sh
rm /usr/local/var/postgres/postmaster.pid
pg_ctl -D /usr/local/var/postgres -l /usr/local/var/postgres/server.log start
@strawberryjello
strawberryjello / ci.org
Last active August 12, 2016 05:43
Testing and CI talk

Continuous integration (CI)

CI step-by-step for a single feature

  • checkout latest version of source code from mainline/master
    • verify first that the build is passing – if it’s failing, fix it first
  • develop feature
  • build source locally (in developer’s working copy)
    • compilation/producing a running version of the app
    • run tests
    • this step should be automated
  • when build passes, integrate changes into mainline (eg, push to master)