Skip to content

Instantly share code, notes, and snippets.

@pedrovasconcellos
pedrovasconcellos / RestSharpWithPollyExample.cs
Last active May 16, 2025 12:30
Example using restsharp with polly
using Polly;
using RestSharp;
using System;
using System.Collections.Generic;
using System.Net;
using System.Text.Encodings.Web;
using System.Text.Json;
using System.Threading.Tasks;
namespace RestSharpWithPolly
@nickrod518
nickrod518 / hb_all_books_dl.js
Last active April 17, 2019 17:17 — forked from graymouser/hb_all_books_dl.js
Humble Bundle book bundles - download all books at once
/*
After purchasing a humble book bundle, go to your download page for that bundle.
Open a console window for the page and paste in the below javascript.
This will download all MOBI, EPUB, PDF HD, CBZ, and Zip formats.
*/
$('a').each(function(i) {
if ($.trim($(this).text()) == 'MOBI|EPUB|PDF( ?\(H.\))?|CBZ|Download') {
$('body').append('<iframe id="dl_iframe_'+i+'" style="display:none;">');
document.getElementById('dl_iframe_'+i).src = $(this).data('web');
@efrecon
efrecon / run.tpl
Last active November 15, 2025 09:12
`docker inspect` template to regenerate the `docker run` command that created a container
docker run \
--name {{printf "%q" .Name}} \
{{- with .HostConfig}}
{{- if .Privileged}}
--privileged \
{{- end}}
{{- if .AutoRemove}}
--rm \
{{- end}}
{{- if .Runtime}}
@graymouser
graymouser / hb_all_books_dl.js
Created February 28, 2016 14:09
Humble bundle book bundles - download all books at once
/*
After purchasing a humble book bundle, go to your download page for that bundle.
Open a console window for the page and paste in the below javascript
*/
$('a').each(function(i){
if ($.trim($(this).text()) == 'MOBI') {
$('body').append('<iframe id="dl_iframe_'+i+'" style="display:none;">');
document.getElementById('dl_iframe_'+i).src = $(this).data('web');
}
});
@yieldthought
yieldthought / install-vnc.sh
Created November 11, 2011 11:06
Install VNC
apt-get install metacity
apt-get install tightvncserver
vncserver -geometry 1024x768 :5
set -o vi
alias s="screen -DRe^Xx work"
alias t="screen -DRe^Xx yt"
export DISPLAY=:5
# ...
# my ubuntu .bashrc needed the following section modifying for xterm-256color support:
# set a fancy prompt (non-color, unless we know we "want" color)
export TERM=xterm-256color
@yieldthought
yieldthought / .screenrc
Created November 11, 2011 10:42
My .screenrc
#
# Example of a user's .screenrc file
#
# This is how one can set a reattach password:
# password ODSJQf.4IJN7E # "1234"
# no annoying audible bell, please
vbell on
@yieldthought
yieldthought / install-vim.sh
Created November 11, 2011 10:26
Install Vim
apt-get install mercurial
apt-get build-dep vim
hg clone https://vim.googlecode.com/hg/ vim
cd vim
./configure --enable-rubyinterp --enable-pythoninterp --with-features=big
make
make install
@yieldthought
yieldthought / .vimrc
Created November 11, 2011 09:27
YieldThought's .vimrc
"Set Mapleader
let mapleader = ","
let g:mapleader = ","
"Theme
colo zenburn
"NERDTree
map <Leader>, :NERDTreeToggle<cr>