Skip to content

Instantly share code, notes, and snippets.

@arathunku
arathunku / lp3.rb
Last active December 15, 2015 12:19
Code to parse Polskie Radio Lista Przebojów site and output spotify urls to make a playlist. Unfortunately, creating playlist in spotify has to be done by hand now.
require 'nokogiri'
require 'open-uri'
require 'json'
require './handleData.rb'
def lista_przebojow_trojki(url=nil)
site = Nokogiri::HTML(open(url))
playlist = []
site.css('#bigList tr').each do |song|

Screencasting Framework

The following document is a written account of the Code School screencasting framework. It should be used as a reference of the accompanying screencast on the topic.

Why you should care about screencasting?

You're probably aren't going to take the time to read this document if you're not interested, but there are a lot of nice side effects caused by learning how to create quality screencasts.

  1. Communicating more effectively - At Envy Labs we produce screencasts for our clients all the time. Whether it's demoing a new feature or for a presentation for an invester, they're often much more effective and pleasent than a phone call or screen sharing.
@arathunku
arathunku / Gemfile
Created April 21, 2013 08:57
Downloading movies information for friend's profile @wkinie
source 'https://rubygems.org'
gem 'nokogiri'
@arathunku
arathunku / ex7.asm
Created May 10, 2013 09:18
Adding and substracting in misp
.text # code section
main:
li $v0, 4
la $a0, a
syscall
li $v0, 5
syscall
move $t0, $v0 #load value a to $t0
li $v0, 4
la $a0, b
@arathunku
arathunku / dot_product.asm
Created May 23, 2013 20:27
Dot product assembly
# Test:
# A = [1,2,3,4,5]
# B = [2,4,6,8,10]
# R = A.B = 2+8+18+32+50 = 110
.data
vectorA: .space 128
vectorB: .space 128
binaryA: .space 128
binaryB: .space 128
ask: .asciiz "How many values will the vector have?\n"
@arathunku
arathunku / Preferences.sublime-settings
Created October 27, 2013 07:32
Base user settings in ST2
{
"auto_complete_commit_on_tab": true,
"detect_slow_plugins": false,
"draw_white_space": "all",
"ensure_newline_at_eof_on_save": true,
"font_size": 11,
"ignored_packages":[],
"ignored_words":[],
"save_on_focus_lost": true,
"smart_indent": true,
@arathunku
arathunku / FeaturesHelper.rb
Created May 14, 2014 15:06
Method which will try to validate a block for a given number of seconds. I'm using it when javascript is responsible for loading another page.
def timeout_expect(seconds=1, &block)
end_at = Time.now + seconds
error = nil
while Time.now < end_at
begin
error = nil
block.call
end_at = Time.now
rescue RSpec::Expectations::ExpectationNotMetError => e
error = e
@arathunku
arathunku / keybase.md
Last active August 29, 2015 14:02
keybase

Keybase proof

I hereby claim:

  • I am arathunku on github.
  • I am arathunku (https://keybase.io/arathunku) on keybase.
  • I have a public key whose fingerprint is DB28 9F0C BDB9 09FF F887 B2C2 ED47 67C4 8BB3 C81F

To claim this, I am signing this object:

#
# xhr(route) # get - default
# xhr([route]) # get - default
# xhr([route, param, config]) # get - default
# xhr('post', [route, params, config])
# xhr('delete', route, params, config)
#
angular.module('app.services')
.factory 'xhr', ($q, $http) ->