Skip to content

Instantly share code, notes, and snippets.

@sbennett33
sbennett33 / howto.md
Last active September 30, 2021 19:17
Newsboat + mpv + youtube-dl

Install Tools

Install Newsboat:

$> brew install newsboat

Install mpv:

$> brew install mpv
@lmarkus
lmarkus / README.MD
Last active March 27, 2024 07:15
Extracting / Exporting custom emoji from Slack

Extracting Emoji From Slack!

Slack doesn't provide an easy way to extract custom emoji from a team. (Especially teams with thousands of custom emoji) This Gist walks you through a relatively simple approach to get your emoji out.

If you're an admin of your own team, you can get the list of emoji directly using this API: https://api.slack.com/methods/emoji.list. Once you have it, skip to Step 3

HOWEVER! This gist is intended for people who don't have admin access, nor access tokens for using that list.

Follow along...

@jmerrifield
jmerrifield / README.md
Created June 24, 2015 18:52
Be careful DRYing up test code

A test for a module performing trivial transformation on data from an external service:

it('returns the first element in the response', function () {
  var serviceResponse = [{a: 1}]
  serviceStub.returns(serviceResponse)
  
  expect(subject()).to.equal(serviceResponse[0])
})
@pnc
pnc / observer.md
Last active September 9, 2023 23:32
Using Erlang observer/appmon remotely

Using OTP's observer (appmon replacement) remotely

$ ssh remote-host "epmd -names"
epmd: up and running on port 4369 with data:
name some_node at port 58769

Note the running on port for epmd itself and the port of the node you're interested in debugging. Reconnect to the remote host with these ports forwarded:

$ ssh -L 4369:localhost:4369 -L 58769:localhost:58769 remote-host
@maguec
maguec / gist:5177489
Created March 16, 2013 17:50
Notes on installation of graphite
sudo apt-get install python-cairo python-memcache python-sqlite memcached python-django-tagging python-django libapache2-mod-python apache2 libapache2-mod-wsgi git-core python-pyparsing python-tz libdbd-mysql-perl libmysqlclient-dev libmysqlclient18 mysql-client-5.5 mysql-client-core-5.5 mysql-common python-mysqldb
mkdir -p /var/tmp/software
cd /var/tmp/software
git clone https://github.com/graphite-project/graphite-web.git
git clone https://github.com/graphite-project/carbon.git
git clone https://github.com/graphite-project/whisper.git
for i in whisper carbon graphite-web; do
@dergachev
dergachev / GIF-Screencast-OSX.md
Last active April 19, 2024 11:00
OS X Screencast to animated GIF

OS X Screencast to animated GIF

This gist shows how to create a GIF screencast using only free OS X tools: QuickTime, ffmpeg, and gifsicle.

Screencapture GIF

Instructions

To capture the video (filesize: 19MB), using the free "QuickTime Player" application:

@brobertsaz
brobertsaz / serversetup.md
Last active July 6, 2020 08:56
Ubuntu 12.04 Ruby, Rails, Nginx, Unicorn

Ubuntu 12.04, Ruby, Rails, Nginx, Unicorn and git-deploy

In the seemlingly endless search for the actual correct and easy way to deploy a Rails app, we have tried several ways. We tried out using Apache2 and running a cluster of Thin servers. With the built in threading of Puma we decided to use it with Nginx.

Server Setup

  • Create new server
  • Login to new server
    • ssh root@IPaddress (you can also use the domain name if you have the DNS setup already)
    • accept the RSA key
@rmcgibbo
rmcgibbo / install.sh
Last active October 9, 2015 03:48
Install Python / numpy / scipy / ipython / matplotlib / umfpack / pytables from source
#!/bin/bash
# =================================================================
# Install a full scientific python stack from source, for Ubuntu, with
# python 2.7.3 (tested on a totally fresh Ubuntu12.04-amd64). Requires
# sudo for apt-getting dependencies like libatlas, Tk, etc
# =================================================================
# packages pulled from PyPI are currently
# scipy 0.10.1
@piscisaureus
piscisaureus / pr.md
Created August 13, 2012 16:12
Checkout github pull requests locally

Locate the section for your github remote in the .git/config file. It looks like this:

[remote "origin"]
	fetch = +refs/heads/*:refs/remotes/origin/*
	url = git@github.com:joyent/node.git

Now add the line fetch = +refs/pull/*/head:refs/remotes/origin/pr/* to this section. Obviously, change the github url to match your project's URL. It ends up looking like this:

@MohamedAlaa
MohamedAlaa / tmux-cheatsheet.markdown
Last active April 23, 2024 15:29
tmux shortcuts & cheatsheet

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname