Skip to content

Instantly share code, notes, and snippets.

Augusts Bautra Epigene

Block or report user

Report or block Epigene

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View Karabiner custom

Karabiner Elements v12.7.0 custom rule setup

  1. Open ~/.config/karabiner/assets/complex_modifications
  2. Make a new *.json rule file
  3. Put the rule json in there.
  4. Reload Karabiner and add the rule.

Control + D to Show Desktop

View gist:e459b4642552f3bb85b58f6bce775369
SELECT `applications`.* FROM `applications` LEFT OUTER JOIN `agreements` `agreements_f0` ON `applications`.`id` = `agreements_f0`.`application_id` WHERE ((`applications`.`hidden` = ? OR `applications`.`hidden` IS ?)) AND ((LOWER(`applications`.`client_name`) LIKE LOWER(?)) OR (LOWER(`applications`.`client_email`) LIKE LOWER(?)) OR (LOWER(`applications`.`client_identification_no`) LIKE LOWER(?)) OR (LOWER(`applications`.`client_phone`) LIKE LOWER(?)) OR (LOWER(`applications`.`client_phone2`) LIKE LOWER(?)) OR (LOWER(`applications`.`client_phone3`) LIKE LOWER(?)) OR (LOWER(`applications`.`client_phone4`) LIKE LOWER(?)) OR (LOWER(`applications`.`vehicle_no`) LIKE LOWER(?)) OR (LOWER(`applications`.`vehicle_vin`) LIKE LOWER(?)) OR (LOWER(`applications`.`vehicle_no2`) LIKE LOWER(?)) OR (LOWER(`applications`.`vehicle_technical_certificate_no`) LIKE LOWER(?)) OR (LOWER(`applications`.`vehicle_technical_certificate_no2`) LIKE LOWER(?)) OR (LOWER(`applications`.`number`) LIKE LOWER(?)) OR (LOWER(`applications`.`reque
Epigene / ruby.json
Last active Aug 31, 2018
Ruby (predominantly RSpec) snippets for VSC.
View ruby.json
"scope spec template": {
"prefix": "scope_spec",
"body": [
"describe \".SCOPE_NAME\" do",
" subject(:collection) { described_class.SCOPE_NAME }",
" context \"when instantiating actual records\", :slow do",
" let!(:match) { create(:FACTORY, :TRAIT) }",
" let!(:counter) { create(:FACTORY) }",
Epigene / Nim
Created Jul 17, 2018
Some know-how and cheats for Nim programming languages
View Nim

Compiling with the -d:release flag will turn the bounds checks off. This will result in higher performance but less safety.

View settings.js
"workbench.colorTheme": "Solarized Dark",
"editor.minimap.enabled": false,
"explorer.fontFamily": "DejaVu Sans Mono",
"explorer.autoReveal": false,
"editor.fontFamily": "DejaVu Sans Mono, 'Courier New', monospace, 'Droid Sans Fallback'",
"editor.tabSize": 2,
"editor.fontSize": 12.5,
"window.zoomLevel": 1,
"editor.rulers": [80, 120],
Epigene / test_service.rb
Created Feb 23, 2018
An example of a service class code created by a rails service generator
View test_service.rb
module V1
module Api
class TestService
# This service TODO
def initialize
def call
Epigene / bundler.config
Created Jan 22, 2018
Make bundler always use some pg_config
View bundler.config
bundle config --with-pg-config=/Applications/
View command+d_to_f11.json
"title": "Command+D show desktop",
"rules": [
"description": "Command+D show desktop",
"manipulators": [
"type": "basic",
"from": {
"key_code": "d",
Epigene / bench_data.csv
Created Oct 14, 2017
Raw data for setup strategy comparison
View bench_data.csv
file line_number group time
./spec/setup_benchmark.rb 9 SetupBenchmark::NewVSAllOthersWhenTestingBookVampireTitle::WhenSettingUpWithNew 0.198
./spec/setup_benchmark.rb 17 SetupBenchmark::NewVSAllOthersWhenTestingBookVampireTitle::WhenSettingUpWithInstanceDouble 0.173
./spec/setup_benchmark.rb 25 SetupBenchmark::NewVSAllOthersWhenTestingBookVampireTitle::WhenSettingUpWithFactoryGirlBuildStubbed 0.396
./spec/setup_benchmark.rb 33 SetupBenchmark::NewVSAllOthersWhenTestingBookVampireTitle::WhenSettingUpWithFactoryGirlBuild 0.916
./spec/setup_benchmark.rb 41 SetupBenchmark::NewVSAllOthersWhenTestingBookVampireTitle::WhenSettingUpWithFactoryGirlCreate 1.155
./spec/setup_benchmark.rb 55 SetupBenchmark::InstanceDoubleVSFactoryGirlBuildStubbedFactoryGirlBuildAndFactoryGirlCreate::WhenSettingUpWithInstanceDouble 0.443
Epigene / book.rb
Created Oct 14, 2017
complete mock
View book.rb
after_save :do_something
def do_something
You can’t perform that action at this time.