Skip to content

Instantly share code, notes, and snippets.

@vsivsi
vsivsi / cleardns.sh
Created May 9, 2017 17:46
Clear DNS cache on El Cap / Sierra
# Run with sudo
dscacheutil -flushcache
killall -HUP mDNSResponder
@vsivsi
vsivsi / fetch_data.sh
Last active April 17, 2017 19:02
Grab event and log data from a Cyperpower UPS with RMCARD205 installed
#! /bin/sh
# Note that this script may fail if there are multiple copies running at the same time
# Or if a person is logged into the device Web Management UI
# It should recover on future runs once the contention is released
# Default read only user/pass
export CPWUSER=device
export CPWPASS=cyber
# Default IP address
export UPSIP=129.168.10.134
@vsivsi
vsivsi / instructions.md
Last active September 11, 2015 18:46
Add Atom editor as a supported application for Papers2 Citations on OS X

Edit the file:

/Applications/Papers2.app/Contents/SharedSupport/Citations.app/Contents/Resources/AppSupportInformation.plist

...
<key>SupportsInsertionOfCitations</key> <!-- Find this key -->
<array>
...
 com.github.atom