Skip to content

Instantly share code, notes, and snippets.

View kaplas's full-sized avatar

Jouni Kaplas kaplas

View GitHub Profile
@kaplas
kaplas / gist:11248521
Last active August 29, 2015 14:00
Observations about replacing Compass with node-sass (using libsass) + autoprefixer

Observations about replacing Compass with node-sass (using libsass) + autoprefixer

  • Node-sass is quite easy to use, but a custom grunt task will always require more custom boilerplate code than ready made compass grunt plugins (didn't try grunt-sass because we needed to use autoprefixer as well)
  • Absolute image paths don't work too well with node-sass. Ie. URL 'images/foo.bar', with node-sass imagePath '' will get transformed into '/images/foo.bar', which will of course break stuff. I had to make a dirty hack to overcome that one.
  • Image URL cache busters are not yet implemented in libsass
  • I couldn't get CSS source maps to work, but there was quite a many variables in our setup (eg. a Vagrant VM), so I'm not sure where the problem actually was
  • Autoprefixer was super easy to use, and worked out of box
  • We weren't using as much Compass mixins as I though we would be, so replacing those with vanilla CSS didn't take too lo
@kaplas
kaplas / feedback.md
Created June 24, 2014 05:24
Clojure training feedback (June 2014)

Clojure training feedback (June 2014)

In June 2014 Futurice bought a two-day Clojure training from Metosin. It was held in our office in Helsinki, and had 20-something participant Helsinki, Tampere and Berlin. I was there as well, as a total Clojure-newbie.

It was two days very well spent. However I felt that there were quite a many things that could have gone better. As I managed to miss the official feedback form, I decided to write this letter. As many of the things I'm going to list here are quite generic things and ideas, I decided to make this into a gist, so other tech trainers can benefit from it as well.

Metosin dudes, don't get me wrong. I'm writing this to help you, not to bash you. I think you are incrediably talented people, and you have all what it takes to give world-class Clojure trainings. I just want to help you to get there.

@kaplas
kaplas / prezto-install.sh
Last active September 28, 2016 07:40
Install prezto to a vagrant/*nix box with a single command
#!/bin/zsh
#
# This script installs prezto into a vagrant/*nix box which already has zsh and oh-my-zsh
# installed. It also replaces the prompt color and enables the git prezto module. If
# executed via the suggested command below, also the default shell is changed into zsh.
# BTW, if using this for a vagrant box, be sure to execute the command while ssh'd into
# the box.
#
# Usage: curl -L https://raw-gist-file-address-here.sh | zsh && chsh -s $(which zsh)
#
@kaplas
kaplas / Raspbmc-for-composite-TV.md
Last active August 29, 2015 14:06
Setting up Raspbmc to be used with an old TV
@kaplas
kaplas / Raspberry-Pi-for-Google-Cloud-Print.md
Last active August 23, 2023 21:45
How to set up a RPi as a Google Cloud Print server
@kaplas
kaplas / Mac.md
Last active August 29, 2015 14:14
Setting up a new Mac

Setting up a new Mac

Folders

  • mkdir ~/Projects

App installs

  • Everything what I own from Mac App Store
  • Latest XCode from Mac App Store
@kaplas
kaplas / .bootstrap-web-app.md
Last active December 5, 2015 17:48
Bootstrap an empty directory easily with web tech assets

Bootstrap an empty directory easily with web tech assets

This is a collection of some aliases that I regularly use to bootstrap an empty directory for web app development.

@kaplas
kaplas / applescripts.md
Last active January 21, 2016 17:10
A collection of useful AppleScripts

A collection of useful AppleScripts, usually to be used with OS X Automator

@kaplas
kaplas / fb-blocker.user.js
Last active January 6, 2016 11:31 — forked from mehedihasan/fb.blocker.user.js
Block/Hide Facebook elements (and do something useful with that time of yours instead!)
// ==UserScript==
// @name Facebook Blocker (by Jouni Kaplas)
// @namespace net.kaplas.fb-blocker
// @include https://*.facebook.com/*
// @include https://facebook.com/*
// @include http://*.facebook.com/*
// @include http://facebook.com/*
// @version 1
// @grant none
// @downloadURL https://gist.github.com/kaplas/31cf00f605667f7430d9/raw/