Skip to content

Instantly share code, notes, and snippets.

Juhamatti Niemelä iiska

Block or report user

Report or block iiska

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
iiska / webpack.config.js
Created Aug 7, 2017
Webpack configuration for my Hugo sites
View webpack.config.js
const webpack = require("webpack");
const ExtractTextPlugin = require("extract-text-webpack-plugin");
const ManifestPlugin = require("webpack-manifest-plugin");
const autoprefixer = require("autoprefixer");
const path = require("path");
module.exports = {
entry: {
main: [
iiska / keybase.txt
Created Jun 4, 2014
Keybase verification
View keybase.txt
Version: GnuPG v1
iiska / candles.rb
Created Dec 4, 2012
Candle puzzle encountered in IRC
View candles.rb
#! /usr/bin/env ruby
# Finds answer to following puzzle
# There are one thousand candles on the altar and one thousand priests
# in the temple. Their god asks the first priest to go and light all
# the candles. Then he has the second priest go to every second candle
# and put it out."
# The third goes to every third candle and, if it is not burning, he
iiska /
Created Oct 24, 2012
Convert sample.jtl to csv
#! /usr/bin/env python
from xml.etree import ElementTree
from xml.sax.handler import ContentHandler
from xml.sax import parse
import csv
iiska /
Created May 7, 2012
Using urllib2 and cookielib to print cookies from GET request
import urllib2
import cookielib
cookie_jar = cookielib.CookieJar()
opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(cookie_jar))
request = urllib2.Request('')
iiska / post-receive
Created Apr 2, 2012
Post-receive hook which generates html from to be used with gitweb
View post-receive
# Post-receive hook script which generates README.html to git-dir from
# found at the head of master branch in repository.
# Gitweb can read the README.html and embed it to the project summary page.
git cat-file blob | markdown > $GIT_DIR/README.html
iiska / problem-50.scm
Created Jan 31, 2012
Scheme solution for Project-Euler problem 50
View problem-50.scm
;; The prime 41, can be written as the sum of six consecutive primes: 41
;; = 2 + 3 + 5 + 7 + 11 + 13
;; This is the longest sum of consecutive primes that adds to a prime
;; below one-hundred.
;; The longest sum of consecutive primes below one-thousand that adds to
;; a prime, contains 21 terms, and is equal to 953.
;; Which prime, below one-million, can be written as the sum of the most
iiska / lut-helper.c
Created Jan 11, 2012
Floating point --> Fixed point --> Bit string conversion for constellation code lookup tables
View lut-helper.c
#include <stdlib.h>
#include <stdio.h>
#include <math.h>
const double qpsk[] = {-1.0, 1.0};
const double qam16[] = {-3.0, -1.0, 3.0, 1.0};
const double qam64[] = {-7.0, -5.0, -1.0, -3.0, 7.0, 5.0, 1.0, 3.0};
/* Generic function for converting short integers to bit string
* representation.
iiska /
Created Jan 9, 2012
Using KWallet and ksshaskpass with ssh-agent
#! /bin/bash
# Put this in ~/.kde/Autostart/
export SSH_ASKPASS=/usr/bin/ksshaskpass
iiska / .ackrc
Created Dec 29, 2011
Configuration for ack tool
View .ackrc
You can’t perform that action at this time.