This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### Keybase proof | |
I hereby claim: | |
* I am mccurdyc on github. | |
* I am mccurdyc (https://keybase.io/mccurdyc) on keybase. | |
* I have a public key whose fingerprint is 4637 521F B8C6 B9CC 3D20 7FBB 9CD9 D30E BB7B 1EEC | |
To claim this, I am signing this object: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# https://rtyley.github.io/bfg-repo-cleaner/ | |
# https://git-scm.com/book/en/v2/Git-Internals-Maintenance-and-Data-Recovery#Removing-Objects | |
java -jar ~/Desktop/bfg-1.13.0.jar --strip-blobs-bigger-than 5M . | |
rm -Rf .git/refs/original | |
rm -Rf .git/logs/ | |
git count-objects -v | |
git tag | grep -v ignorethis | xargs git push --delete origin | |
git tag | grep -v ignorethis | xargs git tag -d | |
git push --tags --force | |
git count-objects -v |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# global grep and replace | |
grep -rl 'old' ./ | xargs sed -i '' 's/old/new/' | |
# global filename grep and replace | |
rename 's/old/new/g' $(find . -name "*old*") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
call plug#begin('~/.vim/plugged') | |
Plug 'prabirshrestha/asyncomplete.vim' | |
Plug 'prabirshrestha/asyncomplete-gocode.vim' | |
Plug 'prabirshrestha/async.vim' | |
Plug 'prabirshrestha/vim-lsp' | |
Plug 'prabirshrestha/asyncomplete-lsp.vim | |
call plug#end() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package output | |
import ( | |
"bytes" | |
"github.com/aws/aws-sdk-go/service/s3/s3iface" | |
"github.com/aws/aws-sdk-go/service/s3/s3manager" | |
) | |
type S3Writer struct { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
select datname,dbid,objid,refclassid,refobjid,deptype,rolname, nspname || '.' || relname as objname, relowner, nspname || '.' || proname as funcname, proowner | |
from pg_shdepend | |
left join pg_roles on (pg_shdepend.refobjid = pg_roles.oid) | |
left join pg_database on (pg_shdepend.dbid = pg_database.oid) | |
left join pg_class on (pg_class.oid = pg_shdepend.objid) | |
left join pg_proc on (pg_proc.oid = pg_shdepend.objid) | |
left join pg_namespace on (pg_namespace.oid in (pg_class.relnamespace, pg_proc.pronamespace)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
for i in {1..5000} | |
do | |
echo $i | |
go test -v &>> out.txt | |
if grep -q 'FAIL' out.txt | |
then | |
break |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
default: build | |
current_tag: | |
@echo $(shell git describe --abbrev=0 --tags `git rev-list --tags --max-count=1`) | |
build: | |
dep ensure -v | |
GOOS=linux GOARCH=amd64 go build -o bin/project . | |
build_container: build |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# original author: https://www.reddit.com/r/i3wm/comments/6ugxvk/set_working_directory_for_terminal/dlsntaw | |
# Open new terminal in same directory as last terminal: | |
function cd { | |
builtin cd $@ | |
pwd > ~/.last_dir | |
} | |
# clobber "file exists" warning | |
# clobber is toggled off below | |
setopt clobber |
NewerOlder