Skip to content

Instantly share code, notes, and snippets.

// For format details, see https://aka.ms/devcontainer.json. For config options, see the
// README at: https://github.com/devcontainers/templates/tree/main/src/docker-existing-docker-compose
{
"name": "From The Heart",
// Update the 'dockerComposeFile' list if you have more compose files or use different names.
// The .devcontainer/docker-compose.yml file contains any overrides you need/want to make.
"dockerComposeFile": [
"../docker-compose.yml",
"docker-compose.yml"

This gist is meant to go along with a twitter thread. You can find that thread here.

I spent some time discussing my experience with Github Copilot. I talked about some of the social implications of this tech. But I also wanted to show examples of how it worked. In some cases, the experience was pretty surprising.

Because the code screenshots on twitter are not very accessible, I've created this gist to capture the code samples. And I've included some of my commentary in code comments.

@polotek
polotek / digital_subscriptions.txt
Created July 30, 2022 23:50
A list of the digital subscriptions we pay money for
1password
ABC Mouse
Airtable
Amazon Prime
Amazon Web Services
Angular University
Apple News
Audible (Aniyia)
Audible (Marco)
Bayview Hill SF

JavaScript Fundamentals

Part 1: Variables

Var & Scope

var greeting = 'Hello';
console.log(greeting); // prints: Hello

if (true) {
  var greeting = 'Hi';
@polotek
polotek / design_docke_template.md
Created April 3, 2019 03:06
Design Doc Template

Design Doc Title

Stakeholders

List stakeholders for project/feature.

Role Person
Dev Owner
Other Dev 1 (Engine)

Keybase proof

I hereby claim:

  • I am polotek on github.
  • I am polotek (https://keybase.io/polotek) on keybase.
  • I have a public key ASAbNgm_MHa7hpanU4BJsVfUrOrDQgmbgyGq8ZXRop-b0Ao

To claim this, I am signing this object:

JSON._dateReviver = function (k,v) {
if (v.length !== 24 || typeof v !== 'string') return v
try {return new Date(v)}
catch(e) {return v}
}
JSON.parseWithDates = function (obj) {
return JSON.parse(obj, JSON._dateReviver);
}
@polotek
polotek / db-launch.sh
Last active April 20, 2016 05:47 — forked from fancyremarker/db-launch.sh
Example: db-launch script to launch the Aptible postgresql database image
# A script for creating aptible postgres databases in containers
container=$(head -c 32 /dev/urandom | md5);
username=${USERNAME:-aptible};
passphrase=${PASSPHRASE:-password};
dbname=${DATABASE:-db}
cname=${CNAME}
extport=${EXTPORT:-5432}
image="${@: -1}";
# Create a data volume
def format_number(num):
numstr = str(num)
chunks = []
while numstr:
numstr, newchunk = numstr[:-3], numstr[-3:]
chunks.append(newchunk)
return ','.join(chunks[::-1])