Skip to content

Instantly share code, notes, and snippets.

@fbcarpinato
fbcarpinato / main.go
Created October 7, 2025 13:02
go observable weak pointer example
package main
import (
"fmt"
"runtime"
"weak"
)
type Observable struct {
subscribers []weak.Pointer[Subscriber]
unbind C-b
set -g prefix C-a
set -g mouse on
set -g default-terminal "screen-256color"
set-option -ga terminal-overrides ",xterm-256color:Tc"
set-window-option -g mode-keys vi
const mode = process.env.NODE_ENV;
const isProduction = mode === 'production';
const CleanWebpackPlugin = require('clean-webpack-plugin');
const HtmlWebpackPlugin = require('html-webpack-plugin');
const UglifyJsPlugin = require('uglifyjs-webpack-plugin');
const config = {
mode,
@fbcarpinato
fbcarpinato / git-aliases
Created January 31, 2018 12:10 — forked from lukalopusina/git-aliases
GIT Aliases
# GIT
# --------------------------------------------
alias ga="git add"
alias gaa="git add ."
alias gc="git commit -m "
alias gp="git push github"
alias gs="git status"
alias nah="git reset --hard; git clean -df;"
# --------------------------------------------
@fbcarpinato
fbcarpinato / Gate.kt
Created December 22, 2017 14:16
StatePattern example
interface IGate {
fun open(): IGate
fun close(): IGate
}
class Gate(private val gateEvents: GateEvents) : IGate {
override fun open(): IGate {
return this.gateEvents.open()
}
@fbcarpinato
fbcarpinato / .vimrc
Created November 19, 2017 00:12
My personal .vimrc configuration
so ./.vim/plugins.vim
let mapleader = ','
syntax on
colorscheme dracula
nmap <Leader>ev :e $MYVIMRC<cr>
nmap <Leader>ep :e ~/.vim/plugins.vim<cr>