Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

View nickcharlton's full-sized avatar

Nick Charlton nickcharlton

View GitHub Profile
@nickcharlton
nickcharlton / content.md
Last active September 28, 2021 16:42
Resources for Kafka/Event Streams
All T470s drivers: https://pcsupport.lenovo.com/at/en/products/laptops-and-netbooks/thinkpad-t-series-laptops/thinkpad-t470s--type-20js-20jt/downloads/driver-list/
BIOS Update: https://pcsupport.lenovo.com/at/en/products/laptops-and-netbooks/thinkpad-t-series-laptops/thinkpad-t470s--type-20js-20jt/downloads/ds120418-bios-update-utility-bootable-cd-for-windows-10-64-bit-81-64-bit-7-32-bit-64-bit-linux-thinkpad-t470s
Dock guide: https://pcsupport.lenovo.com/at/en/solutions/pd028011
@nickcharlton
nickcharlton / content.md
Last active May 28, 2021 16:49
Gist from Drafts

Debugging capybara-table

Bumping Nokogiri to 1.11.5, caused our tests around HTML tables to start failing with ERROR: Recursion limit exceeded. The change that caused this is in commit [#9fcb7d][1] (see also: [the full set of changes][2]), where the recursion limit is restricted to 500 (see: [libxml2 commit][3]), which is how it started happening with this Nokogiri update.

In investigating what was causing this to recur, it seems like we don't need all of capybara-table, as [enough is already included in Capybara itself][4].

I did consider just dropping the dependency, but the Matcher/Renderer classes are key to the usability of our tests — I even tried not using them but trying to factor out the dependency was a horrible experience.

My next step would be to try and switch the Capybara selector that CapybaraTable::RspecMatchers uses to the ones already in Capybara: [table.rb][5] and [table_row.rb][6]. This might be as simple as vendering the RspecMatchers.rb file into the project and seein

@nickcharlton
nickcharlton / content.md
Created May 11, 2021 15:17
Gist from Drafts

Drafts → Basecamp / Trix Rich Text Fields

Problem: Copying text with reference links as Rich Text from Drafts into Basecamp mangles all of the formatting.

Solution:

  1. Inspect Element on the editor
  2. $1.editor.setSelectedRange([0, 0])
  3. Copy as HTML in Drafts
  4. $1.editor.insertHTML(Daily Update …)
@nickcharlton
nickcharlton / how-basecamp-uses-basecamp.md
Created April 3, 2020 15:53
How Basecamp uses Basecamp Notes

How Basecamp uses Basecamp

Recording: https://www.twitch.tv/videos/574380757

  • Points out that nothing has changed with them now WFH; they've always worked this way,
  • HQ is equivalent of a company intranet: docs, files, discussions, etc. Every one has access,
  • Teams are like departments or groups: distinct workspaces for the given team, admin gets to choose who sees what; unless you're added they're hidden,
  • Everything is "commentable": you can discuss things in context on every item,
  • DHH points out that they come back to these; sometimes two years later, giving the example of a an AB test,
  • Everything item exists under a URL; it's always referencable,
@nickcharlton
nickcharlton / Gemfile
Created May 9, 2019 12:21
Alexa Endpoint Demo
source "https://rubygems.org"
gem "sinatra"
[Desktop/landrush-example]% VAGRANT_LOG=debug vagrant up
INFO global: Vagrant version: 2.2.0
INFO global: Ruby version: 2.4.4
INFO global: RubyGems version: 2.6.14.1
INFO global: VAGRANT_DEFAULT_PROVIDER="vmware_fusion"
INFO global: VAGRANT_VMWARE_CLONE_DIRECTORY="/Users/nickcharlton/.vagrant.d/clones"
INFO global: VAGRANT_LOG="debug"
INFO global: VAGRANT_INSTALLER_ENV="1"
INFO global: VAGRANT_EXECUTABLE="/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/bin/vagrant"
INFO global: VAGRANT_INSTALLER_VERSION="2"
@nickcharlton
nickcharlton / swagger.yml
Created October 2, 2018 15:33
A cut down version of the main Swagger example.
---
swagger: "2.0"
info:
description: "This is a sample server Petstore server."
version: "1.0.0"
title: "Swagger Petstore"
termsOfService: "http://swagger.io/terms/"
contact:
email: "apiteam@swagger.io"
license:

Keybase proof

I hereby claim:

  • I am nickcharlton on github.
  • I am nickcharlton (https://keybase.io/nickcharlton) on keybase.
  • I have a public key ASAFoqwDxAc1JTlEzlbe4JdIcxHM00T-YKGtyclZW-kWfAo

To claim this, I am signing this object:

@nickcharlton
nickcharlton / gist:05d7cd0828b2e786571fa5110abe0adb
Last active August 11, 2018 15:08
sassc-rails administrate Review App Build Log
-----> Ruby app detected
-----> Compiling Ruby/Rails
-----> Using Ruby version: ruby-2.4.4
-----> Installing dependencies using bundler 1.15.2
Running: bundle install --without development:test --path vendor/bundle --binstubs vendor/bundle/bin -j4 --deployment
Warning: the running version of Bundler (1.15.2) is older than the version that created the lockfile (1.16.3). We suggest you upgrade to the latest version of Bundler by running `gem install bundler`.
Fetching gem metadata from https://rubygems.org/..........
Fetching version metadata from https://rubygems.org/..
Fetching dependency metadata from https://rubygems.org/.
Fetching rake 12.3.0