Skip to content

Instantly share code, notes, and snippets.

@samv
samv / reply.txt
Created Apr 24, 2018
Reply to a spanish Google Voicer
View reply.txt
He sido suscriptor de Google Voice durante 5 años y esto sucede ocasionalmente.
Ambos teléfonos suenan y ninguna persona hizo la llamada.
Creo que es un servicio de match making de Google.
O eso o los ordenadores de Google se han vuelto autoconscientes y nos están jodiendo.
@samv
samv / soap-request-2.xml
Last active May 24, 2016
ONVIF Response from Dahua IPC-HFW1200
View soap-request-2.xml
<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" ><SOAP-ENV:Header><wsse:Security xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"
xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd">
<wsse:UsernameToken>
<wsse:Username>admin</wsse:Username>
<wsse:Password Type="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#PasswordDigest">DG671R1pCZQXyMiFl04yxSY3dHg=</wsse:Password>
<wsse:Nonce>YSB2YWx1ZSBvZiA1MzY=</wsse:Nonce>
<wsu:Created>2016-05-24T05:29:58Z</wsu:Created>
</wsse:UsernameToken>
</wsse:Security>
@samv
samv / pr-blame.sh
Created Jan 3, 2016
Git Blame script that resolves revision numbers to GitHub PR #'s, remote tags, remote or local branches
View pr-blame.sh
#!/bin/bash
#
# call with '-i' to initialize the repo
self=$(basename "$0")
TEMP="$(getopt n:w:i "$@")"
eval set -- $TEMP
REFS="refs/pr/*"
WIDTH=10
@samv
samv / git-wcpush
Last active Aug 29, 2015
'git wcpush'
View git-wcpush
#!/bin/bash
remote=$1
ssh_target=$(git config remote.$remote.url)
echo "remote $remote, ssh is $ssh_target"
cdup="$(git rev-parse --show-cdup)"
if [ -n "$cdup" ]
then
@samv
samv / output.txt
Last active Aug 29, 2015
Remove 'unknown' json fields
View output.txt
JsonRecord(unknown_json_keys={'foo': 'bar'})
JsonRecord()
@samv
samv / start-ssh-agent
Created Feb 19, 2015
Script to reattach a shell to SSH
View start-ssh-agent
#!/bin/sh
# this script knows how to look in /tmp/ssh-* for SSH agent sockets.
# These are created by the SSH agent, or for hosts you connected to
# with 'ssh -A' (or you set 'ForwardAgent yes' in your .ssh/config).
# the upshot is that if *any* of your current ssh connections have an
# agent connection, then you can run this script and it will set your
# environment variables up in the shell you are currently working in.
@samv
samv / yelpreview.txt
Last active Apr 5, 2016
Letter from a Dentist going out of business to patents: Screw The Perverted Incentives of Insurance Funded Dentistry! Screw some guy on Yelp 5 years ago! Screw free speed, the constitution and HIPPA! Screw it all, I'm starting a website
View yelpreview.txt
Dear Patients,
October 5, 2014
After nearly a decade of practice in the office I set up from scratch,
I have made the difficult decision to close my doors. This letter
will set forth the steps I have taken to ensure your continuity of
care, as well as steps for you to take. Additionally, because I care
deeply about you as patients, I will also share with you a high-level
overview of the series of events that led us to this point. It is my
View gist:34c5013278bf5e36d9f9
Usage: gyp_main.py [options ...] [build_file ...]
gyp_main.py: error: no such option: --no-parallel
gyp ERR! configure error
gyp ERR! stack Error: `gyp` failed with exit code: 2
gyp ERR! stack at ChildProcess.onCpExit (/home/samv/oss/atom/build/node_modules/npm/node_modules/node-gyp/lib/configure.js:340:16)
gyp ERR! stack at ChildProcess.EventEmitter.emit (events.js:98:17)
gyp ERR! stack at Process.ChildProcess._handle.onexit (child_process.js:797:12)
gyp ERR! System Linux 3.11.0-20-generic
gyp ERR! command "node" "/home/samv/oss/atom/build/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
@samv
samv / README.rst
Last active Aug 29, 2015
System info for System76 Pangolin Performance (panp9)
View README.rst
@samv
samv / fedextrackingupdate.txt
Last active Dec 12, 2015
update email from Fedex. Note the use of ISO-8601 style in "Estimated Delivery": no suffix like "Z" or "-8" to indicate the time zone. Also, the "Tracking results as of ..." text is in GMT, but doesn't say that :-). Dates in the log appear to be local time (PST). Lack of alignment due to the bad use of hard tabs in the email. There is a log line…
View fedextrackingupdate.txt
-----------------------------------------------------------------------
This tracking update has been requested by:
Name: Anonymous
E-mail: sam@vilain.net
Tracking number 5244371XXXXXXXX
Ship date Jan 29, 2013
Destination SAN FRANCISCO, CA
Estimated delivery 2013-01-31T00:00:00
Signed for by
You can’t perform that action at this time.