Skip to content

Instantly share code, notes, and snippets.

View aitor's full-sized avatar
👊
Working!

Aitor García Rey aitor

👊
Working!
View GitHub Profile

My Stripe Tax Story

I've been debating for weeks whether or not I was going to write any of this down. I'm a dad with two kids and a house to take care of and a business to run. Adding story-telling like this to my plate is exhausting.

Until yesterday, I had decided to forget about the whole thing, until I received the email that broke the camels back, as it were.

The best way I can describe why I'm writing this email is for the same reason why you might spend two hours dealing with an uncooperative mobile phone carrier to get them to remove that $5 charge on your bill that shouldn't be there. Some combination of the feeling of frustration and injustice that really pushes my proverbial buttons.

In this particular case, the "$5 charge on my phone bill" turned out to be literally hundreds of recurring subscription invoices that Stripe disabled collection for because, apparently, those subscriptions required "location inputs".

Generally speaking, I don't blog much anymore, and the last thing I wa

@solnic
solnic / bare-bone-fp-ruby-objects.rb
Created June 3, 2021 21:03
Bare bone, no-library, no-error handling, just the very core idea behind FP objects in Ruby
class CreateStuff
def initialize(stuff_repo)
@stuff_repo = stuff_repo
end
def call(params)
@stuff_repo.create(params)
end
end

Senior Backend Developer at Devengo

Devengo is a startup focused on a simple but ambitious mission: make finance a fairer place. Founded by well-known fintech players Fernando Cabello-Astolfi and Alberto Molpeceres our first product is an innovative social benefit that allows workers to collect their earned wages in real-time. Your money, when you need it.

The problem

Economists identify¹ three main challenges any person and household must face to reach a sustainable level of financial wellness: having sufficient and stable income, maintaining an economic-financial balance that limits problems of overindebtedness and avoiding severe poverty.

The last two challenges are the most pressing ones as they have an immediate effect on the material living conditions of the population and they compound over time sinking the households' economies further and further.

In Spain al

@tobi
tobi / kindle.rb
Last active September 25, 2022 02:37
Download your Kindle Highlights to local markdown files. Great for Obsidian.md.
#!/usr/bin/env ruby
# gem install active_support
require 'active_support/inflector'
require 'active_support/core_ext/string'
# gem install webrick (only ruby3)
require 'webrick'
# gem install mechanize
@lostfictions
lostfictions / linux-streaming-setup.md
Last active April 16, 2023 02:22
Script to set up (and tear down) PulseAudio sinks for streaming to Discord or Twitch (including, optionally, via a capture device)

A Somewhat Better Setup for Streaming from Linux

I couldn't find a great way to set up streaming to Discord or Twitch from Linux, so I wrote this.

Intro

The script included below, streaming.sh, is meant to be used in tandem with the PulseAudio Volume Control application (pavucontrol, which is available in repositories for most distributions that use Pulse but might not be installed by default). It adds two PulseAudio "sinks" (destinations) that you can

@navarrothiago
navarrothiago / README.md
Last active September 17, 2024 13:22
Turn your smartphone or tablet camera into a WebCam to make video conference in Linux
require 'logger'
require 'byebug'
require 'dry/monads'
require 'dry/monads/do'
require 'dry/matcher/result_matcher'
module Dry
module Transaction
module Steps
@egelev
egelev / connect_bluetooth_headphones.sh
Last active August 28, 2024 11:37
Connect bluetooth headphones on Ubuntu 18.04
#!/usr/bin/env bash
function get_headphones_index() {
echo $(pacmd list-cards | grep bluez_card -B1 | grep index | awk '{print $2}')
}
function get_headphones_mac_address() {
local temp=$(pacmd list-cards | grep bluez_card -C20 | grep 'device.string' | cut -d' ' -f 3)
temp="${temp%\"}"
temp="${temp#\"}"
@matthargett
matthargett / ts-vs-flow.md
Created November 19, 2018 21:00
TypeScript versus flowtype

First, let's note the difference in philosophy: TypeScript aims for fast analysis because you can to compile it down to JS before you can run/test it. flowtype is meant to be an async analysis that can run continuously with changes since the last analysis, or in parallel with your eslint and bundler rules. As such, flowtype's type system and analysis is not quite as concerned with speed or memory usage in service of potentially finding more bugs.

On two occasions I have tried to roll out flow in React Native applications, and on those two occasions we ended up backing out after a few weeks. Some detail: flow doesn't have a public roadmap, and what version you use is dictated by the react/react-native dependency and the annotations in react-native itself. flowtype also has some hard-coded aspects to help the analysis for React, so major updates to React itself sometimes also require updating flowtype to match. React Native upgrades then get gated based on your dependent libraries (or flow-typed) being updated

@igorwwwwwwwwwwwwwwwwwwww
igorwwwwwwwwwwwwwwwwwwww / README.md
Created July 2, 2018 17:48
clickhouse-playground

clickhouse-playground

capture logs:

heroku logs --tail -a travis-api-production | grep at=info | gsed -e 's/^\([0-9]*-[0-9]*-[0-9]*\)T\([0-9]*:[0-9]*:[0-9]*\)/date=\1 time="\1 \2" /' | lcut date time method path host request_id fwd dyno connect service status bytes > access.log

boot: