Skip to content

Instantly share code, notes, and snippets.

View ff6347's full-sized avatar
🤖
updating status…

Fabian Morón Zirfas ff6347

🤖
updating status…
View GitHub Profile
<html>
<head>
<script src="clmtrackr.js"></script>
<script src="model_pca_20_svm.js"></script>
<script src="p5.js"></script>
<script src="p5.dom.js"></script>
<script>
var ctracker;
# Create the sync directory in iCloud
$ mkdir ~/Library/Mobile\ Documents/com~sublimetext~2/
# Move your ST2 "Packages", "Installed Packages" and "Pristine Packages" to iCloud
$ cd ~/Library/Application\ Support/Sublime\ Text\ 2/
$ mv Packages/ ~/Library/Mobile\ Documents/com~sublimetext~2/
$ mv Installed\ Packages/ ~/Library/Mobile\ Documents/com~sublimetext~2/
$ mv Pristine\ Packages/ ~/Library/Mobile\ Documents/com~sublimetext~2/
# Then symlink your iCloud directories back locally
#!/usr/bin/ruby
=begin
Usage: rtftomarkdown.rb FILENAME.rtf
Uses textutil, available on Mac only (installed by default)
Outputs to STDOUT
Notes:
Links are replaced with Markdown references (duplicate links combined).
#!/bin/sh
# Some things taken from here
# https://github.com/mathiasbynens/dotfiles/blob/master/.osx
# Set the colours you can use
black='\033[0;30m'
white='\033[0;37m'
red='\033[0;31m'
green='\033[0;32m'
@ff6347
ff6347 / bitcolor.js
Last active August 29, 2015 14:06 — forked from lrvick/bitcolor.js
// convert 0..255 R,G,B values to binary string
RGBToBin = function(r,g,b){
var bin = r << 16 | g << 8 | b;
return (function(h){
return new Array(25-h.length).join("0")+h
})(bin.toString(2))
}
// convert 0..255 R,G,B values to a hexidecimal color string
RGBToHex = function(r,g,b){
@ff6347
ff6347 / .htaccess
Last active August 29, 2015 14:06 — forked from henrik/.htaccess
RewriteEngine On
# Map http://henrik.nyh.se to /jekyll.
RewriteRule ^$ /jekyll/ [L]
# Map http://henrik.nyh.se/x to /jekyll/x unless there is a x in the web root.
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !^/jekyll/
RewriteRule ^(.*)$ /jekyll/$1
body {
font-family: Helvetica, arial, sans-serif;
font-size: 14px;
line-height: 1.6;
padding-top: 10px;
padding-bottom: 10px;
background-color: white;
padding: 30px; }
body > *:first-child {
// Marius Watz - http://workshop.evolutionzone.com
//
// Window frame control: Disable frame decoration (see
// init() function), manipulate frame position (see
// keyPressed(), draw() )
int framePosX=0;
int framePosY=0;
boolean frameDecorated=false;
//var csv is the CSV file with headers
function csvJSON(csv){
var lines=csv.split("\n");
var result = [];
var headers=lines[0].split(",");
for(var i=1;i<lines.length;i++){
@ff6347
ff6347 / baum.pde
Last active August 29, 2015 14:00 — forked from componieri/gist:11214441
int steps = 7;
int dist;
PVector [] pointset = new PVector [3];
int points = 1;
int oldx = 0;
int oldy = 0;
int _x = 0;
int _y = 0;
int runs = 2;