Skip to content

Instantly share code, notes, and snippets.

@philbot9
philbot9 / ducky.md
Created May 14, 2018 20:19 — forked from schmich/ducky.md
Programming media keys on the Ducky One 2 Skyline

Programming Media Keys on the Ducky One 2 Skyline

To use media keys on the Ducky One 2 Skyline, you must record a macro to bind the media function to a hotkey combination, i.e. Fn plus some key.

Example

Important: In the instructions below, "Press X+Y+Z" means press and hold key X, press and hold key Y, press and hold key Z in that order, and then release all three.

As an example, to bind Fn+PgUp to the play/pause media function:

@philbot9
philbot9 / install-watchman.sh
Created February 10, 2018 16:09 — forked from ivan-loh/install-watchman.sh
Watchman ( 4.9.0 ) installation for Ubuntu 16.04
# checkout, compile & install
git clone https://github.com/facebook/watchman.git
cd watchman/
git checkout v4.9.0
sudo apt-get install -y autoconf automake build-essential python-dev libssl-dev libtool
./autogen.sh
./configure
make
sudo make install
@philbot9
philbot9 / ssh_agent_start.fish
Created July 11, 2017 13:47 — forked from gerbsen/ssh_agent_start.fish
Auto-launching ssh-agent in fish shell
# content has to be in .config/fish/config.fish
# if it does not exist, create the file
setenv SSH_ENV $HOME/.ssh/environment
function start_agent
echo "Initializing new SSH agent ..."
ssh-agent -c | sed 's/^echo/#echo/' > $SSH_ENV
echo "succeeded"
chmod 600 $SSH_ENV
. $SSH_ENV > /dev/null
@philbot9
philbot9 / php-apcu-bc_on_ubuntu_16.04.md
Created August 12, 2016 15:57
Install php-acpu-bc on Ubuntu 16.04

The php-apcu-bc package provides a backwards compatibility layer from apcu -> apc, and is reuqired for some older PHP code bases (e.g. Yii 1). The package is not (yet) available in the Ubuntu 16.04 repos. To install it, use php-pear:

sudo apt-get install php-dev php-pear
sudo pecl install apcu_bc-beta

Then edit /etc/php/7.0/apache2/php.ini and add the following at the end of the file:

@philbot9
philbot9 / 0_reuse_code.js
Last active August 29, 2015 14:18
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console