Skip to content

Instantly share code, notes, and snippets.

View compostbrain's full-sized avatar
🎯
Focusing

Joel Cahalan compostbrain

🎯
Focusing
  • Washington D.C.
View GitHub Profile
@compostbrain
compostbrain / cloudSettings
Created December 6, 2018 14:30
Visual Studio Code Settings Sync Gist
{"lastUpload":"2018-12-06T14:30:00.792Z","extensionVersion":"v3.2.2"}
@compostbrain
compostbrain / gist:a69860d0ac26871c8e2f5e8a1a4ed61e
Created August 1, 2018 15:38
error for chrome dev tools class
events.js:165░░░░░░⸩ ⠼ extract:core-js: sill extract debug@2.6.9
throw er; // Unhandled 'error' event
^
Error [ERR_STREAM_WRITE_AFTER_END]: write after end
at writeAfterEnd (_stream_writable.js:237:12)
at PassThrough.Writable.write (_stream_writable.js:287:5)
at PassThrough.Writable.end (_stream_writable.js:572:10)
at ReadEntry.entry.on (/Users/compost/.nvm/versions/node/v9.8.0/lib/node_modules/npm/node_modules/pacote/lib/extract-stream.js:19:41)
at ReadEntry.emit (events.js:185:15)
@compostbrain
compostbrain / registration_form.rb
Created July 15, 2018 17:04
Understanding codebase
require 'action_view/helpers/translation_helper'
class Registration
# this include add useful ActiveModel behavior
include ActiveModel::Model
# Include `TranslationHelper` so that we can internationalize
# validation error messages
include ActionView::Helpers::TranslationHelper
➜ 02-Installing-and-Using-Relational-Databases git:(02-Installing-and-Using-Relational-Databases) ✗ psql library compost
psql (10.1)
Type "help" for help.
library=# SELECT * FROM books;
id | title | author
------+------------------------------------------+---------------------
1259 | Eloquent Ruby | Russell A. Olson
1593 | JavaScript: The Good Parts | Douglas Crockford
8982 | Designing Object-Oriented Software | Rebecca Wirfs-Brock
@compostbrain
compostbrain / gist:ec9e2fa0be0695474049d64dd025b921
Created July 16, 2017 23:44
code to reproduce wdio config error
node_modules/.bin/wdio config
=========================
WDIO Configuration Helper
=========================
? Where do you want to execute your tests? On my local machine
? Which framework do you want to use? mocha
? Shall I install the framework adapter for you? Yes
? Where are your test specs located? ./e2etests/*.js
Installing wdio packages:
Packages installed successfully, creating configuration file...
fs.js:584
return binding.open(pathModule._makeLong(path), stringToFlags(flags), mode);
^
Error: ENOENT: no such file or directory, open '/Users/compost/Source/testapps/my-react-todolist/node_modules/webdriverio/build/lib/helpers/wdio.conf.ejs'
at Object.fs.openSync (fs.js:584:18)
at Object.fs.readFileSync (fs.js:491:33)
@compostbrain
compostbrain / 0_reuse_code.js
Created March 21, 2017 00:17
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console