Skip to content

Instantly share code, notes, and snippets.

@abitrolly
abitrolly / buildpacknotes.md
Last active April 18, 2020 12:35
What is Buildpack?

It takes your source app code and containerizes it.

Yes, it is a Dockerfile replacement. Instead of creating Dockerfile for every little script you might have, just let the buildpack do the job.

What is lifecycle?

It is a go program that executes logic in buildpacks. Much like docker build . executes Dockerfile, the lifecycle executes buildpack.

Why the hype?

getting mouseless

day1: Ctrl+Shift+P to open command palette. Ctrl+B to hide side panel.

featurecreeps

close side panel with Esc.

--- part 2: dreaming

How I would do this given enough resources? The humanitarian mission of WGC would not be just providing resources, it should also be educational to teach people the infrastructure - how to self host, store the results and share operational costs. The blockchain community did a lot of this in last four years, and a lot more should be done.

First step is transparency. Given the limited resources for only a handful of people, ensure that the whole system is sufficienty


Slow by design

Terminals or "terminal emulators" are slow by design. They use only two streams - input and output for everything. No parallel key presses for battle game, no parallel drawing buffers or event queue from mouse of another controller. Terminals are stateful - you need to wait for output to switch to specific state before you can draw next symbol or process next key command. Terminals lose information about key

@abitrolly
abitrolly / railsnotes.md
Last active March 8, 2021 18:53
Experience patching Ruby on Rails project

in Ruby all access to object attributes is thru methods

  • there is no direct way like obj.field in Python

in Ruby method calls may have no ()

  • obj.method is the same as obj.method()

# get all application routes
@abitrolly
abitrolly / vimnotes
Last active November 2, 2021 10:20
Notes from Vim masterclass by @vitaly-zdanevich @ Minsk Hackerspace
-- Modes --
i #
v # visual selection mode
Ctrl+v # visual block selection
ESC
Ctrl+o # in insert mode - run one command in normal mode
#!/usr/bin/env python3
# Code for drawing a lot of SQLite databases
# https://github.com/yakshaveinc/linux/issues/29#issuecomment-533082911
import os
import sqlite3
from urllib.request import pathname2url
from sqlalchemy_schemadisplay import main
@abitrolly
abitrolly / issue-index-autoconversion-in-series.ipynb
Created July 31, 2019 15:07
Issue - Index Autoconversion in Series.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
#!/usr/bin/env python3
"""
Pull images for `docker-compose build` with ignore filter.
https://github.com/docker/compose/issues/6668
The code is placed into public domain.
"""
import argparse