Skip to content

Instantly share code, notes, and snippets.

View mojoaxel's full-sized avatar
🏠
Working from home

Alexander Wunschik mojoaxel

🏠
Working from home
View GitHub Profile
@mojoaxel
mojoaxel / pt-battery-fw-update_v2.sh
Last active January 10, 2017 19:45
pi-top battery firmware update
pi@pi-top ~ $ wget https://s3-us-west-2.amazonaws.com/pi-top/pt-battery-fw-update_v2
--2016-04-19 07:43:27-- https://s3-us-west-2.amazonaws.com/pi-top/pt-battery-fw-update_v2
Resolving s3-us-west-2.amazonaws.com (s3-us-west-2.amazonaws.com)... 54.231.168.46
Connecting to s3-us-west-2.amazonaws.com (s3-us-west-2.amazonaws.com)|54.231.168.46|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 57760 (56K) [application/octet-stream]
Saving to: `pt-battery-fw-update_v2'
100%[==============================================================================================================================>] 57,760 70.7K/s in 0.8s

Keybase proof

I hereby claim:

  • I am mojoaxel on github.
  • I am wunschik (https://keybase.io/wunschik) on keybase.
  • I have a public key whose fingerprint is 68D7 252B 3D5A 0C27 FA35 64E5 6B87 D9D3 813D AA42

To claim this, I am signing this object:

@mojoaxel
mojoaxel / getImageAndSaveToFTP.sh
Created January 14, 2016 19:42
Upload image from AirCam to Wunderground (FTP)
#!/bin/bash
# Download image from AirCam
curl --insecure -o image.jpg https://XXX.XXX.XXX.XXX/snapshot.cgi?chan=1
# create folder archive if it doesn't already exist
mkdir -p archive
# save image to archive
cp image.jpg archive/webcam_$(date +"%Y%m%d-%H%M").jpg
@mojoaxel
mojoaxel / foreign_key_checks_OFF.sql
Last active October 26, 2017 18:51
Import .sql files as tables to the database with the directoryname they are in.
SET foreign_key_checks = 0;
@mojoaxel
mojoaxel / flot-events.time.html
Created June 18, 2015 12:12
flot-events example using time axes
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Flot-Events Example</title>
<!-- required -->
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/jquery/1.11.2/jquery.min.js" ></script>
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/flot/0.8.3/jquery.flot.min.js"></script>
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/flot/0.8.3/jquery.flot.selection.min.js"></script>
@mojoaxel
mojoaxel / PrintGitHubIssues.ascr
Last active September 24, 2017 09:19 — forked from gaute/githubprint.user.js
Tampermonkey and Actiona Script to print GitHub issues (GitHub version 24.09.17)
<?xml version="1.0" encoding="UTF-8"?>
<scriptfile>
<settings program="actiona" version="3.9.1" scriptVersion="1.1.0" os="GNU/Linux"/>
<actions>
<action name="ActionClick" version="1.0.0"/>
<action name="ActionLoop" version="1.0.0"/>
<action name="ActionWriteText" version="1.0.0"/>
<action name="ActionKey" version="1.0.0"/>
<action name="ActionOpenURL" version="1.0.0"/>
<action name="ActionVariable" version="1.0.0"/>
@mojoaxel
mojoaxel / killall.sh
Created June 24, 2014 12:11
kill all processes containing the given string
#!/bin/bash
ps -ef | grep $1 | grep -v grep | awk '{print $2}' | xargs kill -9
/*
* Retina Images using Handlebars.js
*
* Created by [Makis Tracend](@tracend)
* Released under the [MIT license](http://makesites.org/licenses/MIT)
*
* Usage: <img src="{{retina 'http://mydoma.in/path/to/image.jpg'}}">
*/
Handlebars.registerHelper('retina', function( src ) {
@mojoaxel
mojoaxel / server.js
Last active January 23, 2016 18:23
simple static node.js webserver
var http = require("http");
var url = require("url");
var fs = require("fs");
var port = process.argv[2] || 8080;
var contentTypes = {
'ico': 'image/x-icon',
'html': 'text/html',
'js': 'application/javascript',
'json': 'application/json',
@mojoaxel
mojoaxel / font-boosting.css
Last active July 1, 2019 18:23 — forked from sethlilly/font-boosting.css
Disable font boosting on mobile browsers
/* disable font boosting on mobile browsers */
body * {
max-height: 1000000em; /* Chrome for Android */
-moz-text-size-adjust: none; /* Firefox Mobile */
}