Skip to content

Instantly share code, notes, and snippets.

// ==PREPROCESSOR==
// @import "%fb2k_profile_path%wsh_br3tt\jsplaylist\js\WSHcommon.js"
// @import "%fb2k_profile_path%marc2003\common8.js"
// @name "Thumbs"
// @feature "v1.4"
// @feature "watch-metadb"
// ==/PREPROCESSOR==
//the track info section displays 3 lines of title formatted text. you can customise that here/////////////////////////////////////////////
function Format_hms(t) {
@samithaj
samithaj / genres.txt
Last active August 29, 2015 14:26 — forked from sampsyo/genres.txt
music genre list scraper
2 tone
2-step garage
4-beat
4x4 garage
8-bit
acapella
acid
acid breaks
acid house
acid jazz
var DT_LEFT = 0x00000000;
var DT_CENTER = 0x00000001;
var DT_RIGHT = 0x00000002;
var DT_VCENTER = 0x00000004;
var DT_WORDBREAK = 0x00000010;
var DT_CALCRECT = 0x00000400;
var DT_NOPREFIX = 0x00000800;
var DT_END_ELLIPSIS = 0x00008000;
var MF_GRAYED = 0x00000001;
@samithaj
samithaj / Biography Photos.txt
Last active August 29, 2015 14:27 — forked from mire777/Biography Photos.txt
Biography Photos
// ==PREPROCESSOR==
// @name "Biography Photos"
// @author "Mire777"
// @feature "v1.4"
// @feature "watch-metadb"
// ==/PREPROCESSOR==
// Paths
var fbfolder = (fb.ProfilePath + "Artist_info");
var lfm_folder = window.GetProperty("Custom folder", fbfolder);
@samithaj
samithaj / Subreddit-to-YouTube-Source-Bookmarklet.md
Created October 19, 2015 14:28 — forked from akaleeroy/Subreddit-to-YouTube-Source-Bookmarklet.md
Subreddit to YouTube Source Bookmarklet - Play YouTube music from subreddits in Foobar with foo_youtube

Subreddit to YouTube Source Bookmarklet

Generates .M3U playlist of all YouTube videos in current subreddit listing for use in foobar2000 with the foo_youtube component.

First off, foo_youtube is awesome! It enables you to listen to YouTube songs in Foobar, which opens up possibilities like making playlists, enqueuing tracks, remembering playback state, quickly mixing in a song you don't have in your library, using DSPs like Channel Mixer (surround sound up-mixing from stereo works wonders!). You're also free to restart the browser, and you don't have to wonder which of the hundred tabs the sound is coming from, LOL.

How to install

  1. Copy the contents of the second file Subreddit-to-YouTubeSource.min.js

  2. Add a new bookmark

I, [2016-02-03T23:06:27.370137 #6556] INFO -- development-ubuntu-1404: -----> Converging <development-ubuntu-1404>...
I, [2016-02-03T23:06:27.373121 #6556] INFO -- development-ubuntu-1404: Preparing files for transfer
I, [2016-02-03T23:06:27.373640 #6556] INFO -- development-ubuntu-1404: Preparing dna.json
I, [2016-02-03T23:06:27.376623 #6556] INFO -- development-ubuntu-1404: Resolving cookbook dependencies with Berkshelf 4.0.1...
I, [2016-02-03T23:06:29.957831 #6556] INFO -- development-ubuntu-1404: Removing non-cookbook files before transfer
I, [2016-02-03T23:06:30.189201 #6556] INFO -- development-ubuntu-1404: Preparing data_bags
I, [2016-02-03T23:06:30.192186 #6556] INFO -- development-ubuntu-1404: Preparing environments
I, [2016-02-03T23:06:30.195689 #6556] INFO -- development-ubuntu-1404: Preparing roles
I, [2016-02-03T23:06:30.196688 #6556] INFO -- development-ubuntu-1404: Preparing validation.pem
I, [2016-02-03T23:06:30.199190 #6556] INFO -- development-ubuntu-1404: Preparing client.rb
I, [2016-03-06T11:42:21.600234 #6908] INFO -- development-ubuntu-1404: -----> Converging <development-ubuntu-1404>...
I, [2016-03-06T11:42:21.604145 #6908] INFO -- development-ubuntu-1404: Preparing files for transfer
I, [2016-03-06T11:42:21.605123 #6908] INFO -- development-ubuntu-1404: Preparing dna.json
I, [2016-03-06T11:42:21.619786 #6908] INFO -- development-ubuntu-1404: Resolving cookbook dependencies with Berkshelf 4.0.1...
I, [2016-03-06T11:42:27.480850 #6908] INFO -- development-ubuntu-1404: Removing non-cookbook files before transfer
I, [2016-03-06T11:42:29.609364 #6908] INFO -- development-ubuntu-1404: Preparing data_bags
I, [2016-03-06T11:42:29.624376 #6908] INFO -- development-ubuntu-1404: Preparing environments
I, [2016-03-06T11:42:29.633382 #6908] INFO -- development-ubuntu-1404: Preparing roles
I, [2016-03-06T11:42:29.647392 #6908] INFO -- development-ubuntu-1404: Preparing validation.pem
I, [2016-03-06T11:42:29.657399 #6908] INFO -- development-ubuntu-1404: Preparing client.rb
@samithaj
samithaj / lastexport.py
Created April 28, 2016 16:00 — forked from bitmorse/lastexport.py
lastfm scrobble exporter (from https://gitorious.org/fmthings/lasttolibre/blobs/master/lastexport.py // changed the script to try more often on failure )
#!/usr/bin/env python
#-*- coding: utf-8 -*-
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
@samithaj
samithaj / .bash_profile
Created May 23, 2016 21:00 — forked from natelandau/.bash_profile
Mac OSX Bash Profile
# ---------------------------------------------------------------------------
#
# Description: This file holds all my BASH configurations and aliases
#
# Sections:
# 1. Environment Configuration
# 2. Make Terminal Better (remapping defaults and adding functionality)
# 3. File and Folder Management
# 4. Searching
# 5. Process Management
@samithaj
samithaj / radialBasis.scala
Created December 14, 2016 03:44 — forked from micrypt/radialBasis.scala
Radial Basis Function
import scala.math.{E, pow}
// Vector length
def vecLength(implicit values: List[Double]) = pow(values.sum, .5)
// Radial basis function
def rbf(v1: List[Double], v2: List[Double], gamma:Int = 20) = {
val dv = { for(i <- (0 to v1.length)) yield (v1(i)-v2(i)) }.toList
val l = vecLength(dv)
pow(E, (-gamma*l))