Skip to content

Instantly share code, notes, and snippets.

@ggsalas
ggsalas / kitty.conf
Last active January 10, 2023 18:34
Kitty terminal - one dark theme [~/.config/kitty/kitty.conf]
# vim:fileencoding=utf-8:ft=conf:foldmethod=marker
#: Fonts {{{
#: kitty has very powerful font management. You can configure
#: individual font faces and even specify special fonts for particular
#: characters.
# font_family Monaco
font_family Source Code Pro
@ashee
ashee / awsips-dnsmasq.md
Last active May 19, 2022 07:19
dnsmasq in osx (macSierra) to resolve aws internal ip's

AWS internal ip's

EMR has components running on internal ip's such as ip-172-23-53-101.ec2.internal. To resolve to the implied public/vpn IP's, setup dnsmasq

Setup dnsmasq

$ brew install dnsmasq

Configure dnsmasq

@doubleirish
doubleirish / kafka_wireshark.md
Created August 4, 2016 16:41
Using Wireshark to sniff kafka message packets on ubuntu

#Using wireshark to sniff kafka messages

Install the latest WireShark application

 sudo add-apt-repository ppa:wireshark-dev/stable
 sudo apt-get update
 sudo apt-get install wireshark
@peter
peter / clojure_vs_java_8.md
Last active August 13, 2017 15:50
Readability of Clojure vs Java 8 Streams

Java:

public Optional<String> getType() {
    return this.types.isEmpty() ?
        Optional.empty() :
        Optional.of(String.join(",", (Iterable)this.types.stream().map(Enum::name).collect(Collectors.toList())));
}
@debasishg
debasishg / gist:6c13f3f57080a9655463
Last active July 31, 2018 01:37
links to papers / books on succinct data structures ..
From Theory to Practice: Plug and Play with Succinct Data Structures - Simon Gog, Timo Beller, Alistair Moffat & Matthias Petri (http://arxiv.org/pdf/1311.1249v1.pdf)
Succinct Data Structures for Retrieval and Approximate Membership - Martin Dietzfelbinger and Rasmus Pagh (http://www.itu.dk/people/pagh/papers/bloomier.pdf)
Lecture 17 in Erik Demaine's 6.851 (https://courses.csail.mit.edu/6.851/spring12/lectures/L17.html)
Succinct Data Sstructures by Edward Kmett (https://www.youtube.com/watch?v=uA0Z7_4J7u8)
Succinct Trees in Practice by Diego Arroyuelo, Rodrigo Ćanova, †Gonzalo Navaror Kunihiko Sadakane http://users.dcc.uchile.cl/~darroyue/papers/alenex2010.pdf
@piscisaureus
piscisaureus / pr.md
Created August 13, 2012 16:12
Checkout github pull requests locally

Locate the section for your github remote in the .git/config file. It looks like this:

[remote "origin"]
	fetch = +refs/heads/*:refs/remotes/origin/*
	url = git@github.com:joyent/node.git

Now add the line fetch = +refs/pull/*/head:refs/remotes/origin/pr/* to this section. Obviously, change the github url to match your project's URL. It ends up looking like this:

@dahlia
dahlia / lisp.rb
Created September 2, 2010 07:52
30 minutes Lisp in Ruby
# 30 minutes Lisp in Ruby
# Hong Minhee <http://dahlia.kr/>
#
# This Lisp implementation does not provide a s-expression reader.
# Instead, it uses Ruby syntax like following code:
#
# [:def, :factorial,
# [:lambda, [:n],
# [:if, [:"=", :n, 1],
# 1,