Skip to content

Instantly share code, notes, and snippets.

iOS, Capacitor, Ember, Vue, Rails

Benjamin Borowski typeoneerror

iOS, Capacitor, Ember, Vue, Rails
View GitHub Profile

(1) First Day on Duty

Today is for firsts

My first #ship30for30 essay. It's also my first day on "duty" as an alternate lieutenant at the Halfmoon Bay Volunteer Fire Department. I'll spend the week on-call 24/7—ready for response—emergency and non-emergency.

I started the morning helping EMS with a stage 4 cancer patient. Car 1 (my duty designation and truck) is parked in the driveway, prepared to respond when I receive a page.

And, to be perfectly honest, today I feel more prepared to lead an interior attack on a burning structure than to write a 250 word essay. But then, I didn't get to where I am as a volunteer firefighter by avoiding scary unknowns.

typeoneerror /
Last active Feb 25, 2021
Helper for yarn linking PN node modules
View workflow.yml
# This works for PUSH but not PULL_REQUEST
if: "!contains(github.event.head_commit.message, '[skipci]')"
# So down here in the STEP, grab the commit message via git log
# But now how do I EXIT the workflow??
- name: Skip if commit contains skipci
run: |
commitmsg=$(git log --format=%B -n 1 ${{ github.event.after }})
View orderable.rb
module Orderable
extend ActiveSupport::Concern
module ClassMethods
# Run a "single" query to update multiple records by a position field.
# The Array of passed in IDs are sorted in the order they are provided in the array.
View confirm-transition.js
// mixins/confirm-transition.js
import Ember from 'ember';
const {
} = Ember;
typeoneerror /
Last active Jul 18, 2018
Key-Value CSS validation concept


I realize your app may not be ruby-based, but here's how I've worked with this dilemma in mind in our app. To start, yes, we don't necessarily support custom CSS, but I do have a database field I (as admin) can add custom CSS to a customer's account template (in the case they have "premium support" or something). Our publicly customizable style settings are key:value based and stored as a JSON object in psql as you suggested might be an option. Here's how I make it less unweildy:

Field in the database:

t.json :settings
View drip-es6.js
// @flow
* {
* success: true,
* visitor_uuid: "f627ee608adb01315d1022000ab2058a",
* anonymous: false,
* email: "",
* custom_fields: { "name": "John" },
* tags: ["Customer"],
View repair_progress_spec.rb
unlock_tests = [
['ULLL', 'ULLL'], # first unlocked, do nothing
['LLLL', 'ULLL'], # first should be unlocked
['LULL', 'UULL'],
['LLUL', 'UUUL'],
['LLLU', 'UUUU'],
['UULL', 'UULL'],
View dictionary-observable.js
// mixins/dictionary-observable.js
import Ember from 'ember';
const {
} = Ember;
View sidekiq.rb
require 'sidekiq/web'
redis_options = { url: ENV['REDIS_URL'] }
Sidekiq.configure_server do |config|
config.redis = redis_options
Sidekiq.configure_client do |config|
config.redis = redis_options