Skip to content

Instantly share code, notes, and snippets.

#include <iterator>
#include <algorithm>
#include <schemese/scanner.h>
using namespace Schemese;
extern int yylex();
extern int yyleng;
extern char* yytext;
ScannerBuffer Scanner::buffer;
@alksl
alksl / mongodb.md
Created September 24, 2014 14:44
Setup MongoDB windows

Install MongoDB on windows

Fetch mongodb from http://www.mongodb.org/downloads

Select Windows x64

This guide explains the installation steps in detail

 http://docs.mongodb.org/manual/tutorial/install-mongodb-on-windows/
@alksl
alksl / README.md
Created September 17, 2014 08:35
Pre commit hook for checking whitespace

Instructions

Copy pre-commit to .git/hooks/pre-commit

saturn# cd /usr/ports/net-p2p/transmission-daemon
saturn# make install
===> Options unchanged
===> License GPLv2 accepted by the user
===> transmission-daemon-2.82_1 depends on file: /usr/local/sbin/pkg - found
=> transmission-2.82.tar.xz doesn't seem to exist in /usr/ports/distfiles/.
=> Attempting to fetch http://transmission.cachefly.net/transmission-2.82.tar.xz
fetch: http://transmission.cachefly.net/transmission-2.82.tar.xz: Not Found
=> Attempting to fetch http://distcache.FreeBSD.org/ports-distfiles/transmission-2.82.tar.xz
transmission-2.82.tar.xz 100% of 3097 kB 1515 kBps 00m02s
#!/bin/zsh
if [ "$#" -ne 2 ]; then
echo "Usage: $0 [infile] [outfile]"
exit 1
fi
export PGPASSWORD=password
pushd gitlab-5-0
---
- :code: TAMS27
:name: Matematisk statistik
:points: 6.0
- :code: TAOP33
:name: Kombinatorisk optimering gk
:points: 4.0
- :code: TATA24
:name: Linjär algebra
:points: 8.0
$ rails new vinylcollections
$ cd vinylcollections
$ git init
$ tmux new -s rails_demo
tmux: C-b C-c
$ rails server
show
$ rails g controller welcome index
routes.rb: root "welcome#index"
show
$ rails new vinylcollections
show
$ rails g controller welcome index
routes.rb: root "welcome#index"
Gemfile: gem 'bootstrap-sass', '~> 3.1.1'
$ bundle update
application.css: *= require bootstrap
$ cp ~/prep/welcome/index.html.erb app/views/welcome/index.html.erb
$ cp ~/prep/superhero.css vendor/assets/stylesheets/superhero.css
application.css: *= require superhero
"issues": {
{
"cover_url": "http://userserve-ak.last.fm/serve/126/90529887.png",
"title": "Uprising",
"artist:" "Bob Marley & The Wailers"
},
{
"cover_url": "http://userserve-ak.last.fm/serve/126/98255213.png"
"title": "Dark side of the moon",
"artist": "Pink Floyd"
var App = Ember.Application.create();