Skip to content

Instantly share code, notes, and snippets.

@janisz
janisz / .tmux.conf
Created July 6, 2017 19:39
.dotfiles
# 0 is too far from ` ;)
set -g base-index 1
# http://www.rushiagr.com/blog/2016/06/16/everything-you-need-to-know-about-tmux-copy-pasting/
bind-key -t vi-copy 'v' begin-selection
#bind-key -t vi-copy 'y' copy-selection
# https://coderwall.com/p/4b0d0a/how-to-copy-and-paste-with-tmux-on-ubuntu
bind -t vi-copy y copy-pipe "xclip -sel clip -i"
bind-key -t vi-copy 'r' rectangle-toggle

Keybase proof

I hereby claim:

  • I am janisz on github.
  • I am janisz (https://keybase.io/janisz) on keybase.
  • I have a public key whose fingerprint is 4F45 E375 6863 9607 7B74 3B09 6342 4686 2E6A B39C

To claim this, I am signing this object:

Keybase proof

I hereby claim:

  • I am janisz on github.
  • I am janisz (https://keybase.io/janisz) on keybase.
  • I have a public key ASCpZ-hU8zLclXsoqT0Jx9LztTlq7KVMi2Wn4wOUhhqFBwo

To claim this, I am signing this object:

@janisz
janisz / defer_test.go
Created January 14, 2020 11:01
Go 1.14 defer benchmark
package bigcache
import "testing"
var sink = 0
func BenchmarkNotDefered(b *testing.B) {
for n := 0; n < b.N; n++ {
notDefered()
}
@janisz
janisz / data.json
Created February 27, 2020 13:08
ClearUrls
{
"providers": {
"amazon": {
"urlPattern": "(https:\\/\\/|http:\\/\\/)([a-zA-Z0-9-]*\\.)?(amazon)(\\.[a-zA-Z]{2,})(.*\\?.*)",
"completeProvider": false,
"rules": [
"pf_rd_[a-zA-Z]=[^\\/|\\?|&]*(\\/|&(amp;)?)?",
"qid=[^\\/|\\?|&]*(\\/|&(amp;)?)?",
"sr=[^\\/|\\?|&]*(\\/|&(amp;)?)?",
"srs=[^\\/|\\?|&]*(\\/|&(amp;)?)?",