Skip to content

Instantly share code, notes, and snippets.

@connerbrooks
connerbrooks / cgd-werc.service
Last active January 8, 2018 09:15
cgd for swerc or werc with systemd
[Unit]
Description=Job that runs cgd for my cool swerc site.
[Service]
Type=simple
ExecStart=/home/cbrooks/develop/bin/cgd -f -c /home/cbrooks/swerc/bin/werc.rc
@OsandaMalith
OsandaMalith / obfuscated.cpp
Last active May 19, 2019 18:10
Obfuscating a String using C++
/??/
* Title: Obfuscating a String using C++
* by @OsandaMalith
*??/
/
??=include <iostream>
??=include <string>
??=include <stdlib.h>
@TjWallas
TjWallas / AndroidVimeo.java
Created April 22, 2013 06:59
Embedding Vimeo Videos using WebView on Android
//Auto playing vimeo videos in Android webview
mWebView.getSettings().setJavaScriptEnabled(true);
mWebView.getSettings().setAppCacheEnabled(true);
mWebView.getSettings().setDomStorageEnabled(true);
// how plugin is enabled change in API 8
if (Build.VERSION.SDK_INT < 8) {
mWebView.getSettings().setPluginsEnabled(true);
} else {
mWebView.getSettings().setPluginState(PluginState.ON);
@btoone
btoone / curl.md
Last active March 4, 2024 15:53
A curl tutorial using GitHub's API

Introduction

An introduction to curl using GitHub's API.

The Basics

Makes a basic GET request to the specifed URI

curl https://api.github.com/users/caspyin
@joergschiller
joergschiller / a2dp_sink_ubuntu_linux.md
Created January 24, 2012 23:05
A2DP Sink on Ubuntu Linux with bluez (streaming bluetooth stereo audio from smartphone to pc)

Howto Enable and Use A2DP Sink on Ubuntu Linux with Bluez

  1. Add Enable=Source to /etc/bluetooth/audio.conf right after [General].

  2. Find address in form XX:XX:XX:XX:XX:XX of phone with hcitool scan.

  3. Pair and trust smartphone with sudo bluez-simple-agent hci0 XX:XX:XX:XX:XX:XX and sudo bluez-test-device trusted XX:XX:XX:XX:XX:XX yes.

  4. Create loopback in pulseaudio connection bluetooth a2dp source with alsa sink:

@kinopyo
kinopyo / gist:1062397
Created July 3, 2011 17:17
How to install coffee-script, and how to enable textmate bundler to compile coffeescript
# don't forget to update your port tree first
sudo port selfupdate
# install coffee script using macport
sudo port install nodejs
node -v
# install npm - the Node Package Manager
git clone http://github.com/isaacs/npm.git
cd npm