Skip to content

Instantly share code, notes, and snippets.

Avatar
☺️

Mike Arvela mieky

☺️
View GitHub Profile
@mieky
mieky / html5-camera-test.html
Last active Mar 28, 2022
HTML5 camera test
View html5-camera-test.html
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<title>HTML5 camera test</title>
<meta name="viewport" content="width=device-width,initial-scale=1">
</head>
<body>
<form>
@mieky
mieky / exiftool-android41.txt
Created Nov 28, 2012
Comparison of EXIF data on a portrait image taken via device web browser
View exiftool-android41.txt
ExifTool Version Number : 9.06
File Name : last-android.jpg
Directory : .
File Size : 1010 kB
File Modification Date/Time : 2012:11:27 17:01:08+02:00
File Access Date/Time : 2012:11:28 10:28:02+02:00
File Permissions : rwxr-xr-x
File Type : JPEG
MIME Type : image/jpeg
Exif Byte Order : Little-endian (Intel, II)
@mieky
mieky / local_deploy.sh
Created Dec 19, 2012
A helper script for deploying a WAR file to a local Tomcat container (with Manager & JMX enabled in tomcat-users.xml for username/password)
View local_deploy.sh
#!/bin/bash
if [ "$#" -ne 1 ];
then
echo "This script deploys a WAR file to a local Tomcat container."
echo "Usage: $0 <war_file>"
exit 1
fi
WAR_FILE=$1
@mieky
mieky / ununzip.sh
Created May 9, 2013
Un-unzip a file without a root folder that spews its contents all around the place.
View ununzip.sh
#!/bin/bash
# A bash-wrapped version of http://www.commandlinefu.com/commands/view/9536/un-unzip-a-file
if [ $# -eq 0 ]; then
echo "Un-unzips a file without a root folder."
echo "Usage: ununzip <filename>"
exit 1
elif [ ! -e $1 ]; then
echo "File not found: $1"
exit 1
fi
@mieky
mieky / isyyspakkauta.js
Last active Dec 20, 2015
Bookmarklet to conveniently browse Isyyspakkaus in-line with just the left/right arrow keys.
View isyyspakkauta.js
;(function($) {
var url = 'http://www.lily.fi/blogit/isyyspakkaus';
if (window.location.href !== url) {
window.location = url;
return;
}
var links = $(".blog-archive-list").find("a").get().reverse();
var currentIndex = parseInt(localStorage.getItem("currentIndex") || 0, 10);
@mieky
mieky / mokuplam.itermcolors
Last active Dec 21, 2015
iterm2 color scheme and matching themes for zsh + irssi
View mokuplam.itermcolors
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Ansi 0 Color</key>
<dict>
<key>Blue Component</key>
<real>0.11764705926179886</real>
<key>Green Component</key>
<real>0.11372549086809158</real>
@mieky
mieky / gist:8646454
Created Jan 27, 2014
jvisualvm over ssh
View gist:8646454
on the remote (Ubuntu) machine:
/etc/default/tomcat7
->
JAVA_OPTS = "-Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.port=1098"
sudo service tomcat7 restart
on the local machine:
@mieky
mieky / group_jquery_events.js
Last active Aug 29, 2015
Calculate events bound via jQuery
View group_jquery_events.js
function getEvents(sel) {
return $(sel).toArray().reduce(function(acc, el) {
var events = $._data(el, 'events');
if (events) acc.push(events);
return acc;
}, []);
}
function calculateEvents(acc, obj) {
for (key in obj) {
@mieky
mieky / keybase.md
Last active Aug 29, 2015
My Keybase proof
View keybase.md

Keybase proof

I hereby claim:

  • I am mieky on github.
  • I am mieky (https://keybase.io/mieky) on keybase.
  • I have a public key whose fingerprint is 350A B06C 792A 82F1 366D E963 93D7 B993 577E ED8B

To claim this, I am signing this object:

@mieky
mieky / config.cson
Last active Aug 29, 2015 — forked from viljamis/config.cson
My Atom editor settings. Context & screenshot: https://twitter.com/mieky/status/504594698586308608
View config.cson
'editor':
'lineHeight': 1.45
'softWrap': true
'normalizeIndentOnPaste': true
'tabLength': 2
'preferredLineLength': 100
'invisibles':
'cr': ''
'eol': ''
'space': '·'