Skip to content

Instantly share code, notes, and snippets.


Steve Clarke steveclarke

View GitHub Profile
View .ideavimrc
let mapleader = " "
nnoremap <Space> <Nop>
" nobody wants that bell!
set visualbell
set incsearch
set hlsearch

Custom Builder for Breadcrumbs on Rails with Bootstrap 5:

# app/lib/bootstrap_five_breadcrumbs.rb
class BootstrapFiveBreadcrumbs < BreadcrumbsOnRails::Breadcrumbs::SimpleBuilder
  def render
    return '' if @elements.size == 0

    @options[:outer_tag] ||= :ol
    @options[:tag] ||= :li
View grid-categories.html
<!DOCTYPE html>
<html lang="en">
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
body {
margin: 1rem;
View responsive-grid-with-aspect-ratio.html
<!DOCTYPE html>
<html lang="en">
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
/* */
.grid {
View Install Android SDK CLI Ubuntu 20.04

Install Android SDK CLI Ubuntu 20.04 WSL2 (Work in Progress)

Install Java 8

sudo apt install openjdk-8-jdk-headless

Android SDK

steveclarke / components.js
Created Sep 26, 2019
Globally register your custom components in Quasar. Add this file to your /boot dir
View components.js
// Globally register all base components for convenience, because they
// will be used very frequently. Components are registered using the
// PascalCased version of their file name.
import upperFirst from 'lodash/upperFirst'
import camelCase from 'lodash/camelCase'
export default async ({ Vue }) => {
console.log('loading components')
steveclarke / gist:d7412ee4d38b712c8226b156d1260354
Created Feb 23, 2018 — forked from forgotpw1/gist:0dd4df2674a2f302fb0b3ffb3d1fb5df
Upgrading quasar framework - Maintaining old quasar-cli on upgrades
View gist:d7412ee4d38b712c8226b156d1260354
Install the 0.14-compatible quasar-cli as a dev dependency in your legacy project:
npm install --save-dev quasar-cli@0.6.5
this will place the legacy cli in your project node_modules
to run quasar for your project:
npx quasar dev etc
npx is a wrapper that runs ./node_modules/.bin/quasar
source: steveclarke @ quasar discourse channel 2.23.2018
View cinst.bat
cinst GoogleChrome
cinst 7zip
cinst git.install
cinst putty
cinst ruby
cinst ruby.devkit
cinst RubyMine
cinst SourceTree
View wercker.yml
box: wercker/ubuntu12.04-ruby1.9.3
- wercker/postgresql
# The steps that will be executed on build
- script:
name: Enable virtual display
code: |-
# Start xvfb which gives the context an virtual display
View Gemfile
source :rubygems
# We are not loading Active Record, nor Active Resources etc.
# We can do this in any app by simply replacing the rails gem
# by the parts we want to use.
gem "actionpack", "~> 4.0"
gem "railties", "~> 4.0"
gem "tzinfo"
# Let's use thin