Skip to content

Instantly share code, notes, and snippets.

Keybase proof

I hereby claim:

  • I am manuelgu on github.
  • I am manuelgutmann (https://keybase.io/manuelgutmann) on keybase.
  • I have a public key ASDFVR06ZYzO_GiS4nLxJPURRM8Fk03rqwfbY0vWDqsczgo

To claim this, I am signing this object:

@manuelgu
manuelgu / mostRecent.sh
Created May 24, 2016 19:14
Download the most recent minecraft version (snapshot)
#!/bin/bash
# Download version file
wget -qN https://launchermeta.mojang.com/mc/game/version_manifest.json
# Beautify the file
python -m json.tool version_manifest.json > versions.json
# Get the latest snapshot release
MCVER=`sed -n -e '/\"latest\"/,/}/ s/.*\"snapshot\": \"\([^\"]*\)\".*/\1/p' < versions.json`
@manuelgu
manuelgu / types.txt
Created December 21, 2015 20:47
Valid action types for the Trello API
CREATE_CARD = "createCard";
COMMENT_CARD = "commentCard";
UPDATE_CARD = "updateCard";
UPDATE_CARD_ID_LIST = "updateCard:idList";
UPDATE_CARD_CLOSED = "updateCard:closed";
UPDATE_CARD_DESC = "updateCard:desc";
UPDATE_CARD_NAME = "updateCard:name";
ADD_MEMBER_TO_CARD = "addMemberToCard";
REMOVE_MEMBER_FROM_CARD = "removeMemberFromCard";
UPDATE_CHECK_ITEM = "updateCheckItemStateOnCard";
@manuelgu
manuelgu / chat.js
Last active March 31, 2016 19:52
Highlight most recent messages in a youtube stream chat
// ==UserScript==
// @name Chat Announcer Thingy
// @namespace https://manuelgu.eu
// @version 1.0
// @description Try to take over the world!
// @author manuelgu
// @match https://www.youtube.com/live_chat*
// @grant none
// ==/UserScript==
@manuelgu
manuelgu / weather.sh
Created February 22, 2016 10:05
Get weather data for your home town in real-time to the terminal
#!/bin/bash
while true
do
# Clear the screen
clear
# Hide the cursor
tput civis
# Fetch data and replace last line for aesthetics
curl -4 -s wttr.in/ham | sed '$d'
# Wait 10 seconds
@manuelgu
manuelgu / ReplayMod Hide Sticky Threads
Last active December 29, 2015 10:25
Add this to a new Tampermonkey / Greasemonkey script and your replaymod.com experience will improve!
// ==UserScript==
// @name ReplayMod Enhancements
// @namespace https://www.replaymod.com/*
// @version 1.0
// @description Adds a few enhancements to replaymod.com
// @author manuelgu
// @match https://www.replaymod.com/*
// @grant none
// ==/UserScript==
@manuelgu
manuelgu / Crash.java
Last active September 29, 2015 16:53
public class Bluescreen {
public static final Map Objects = new HashMap();
public static double d = 0.0;
public static void main(String[] args) throws InterruptedException, IOException{
String jarname = new File(Bluescreen.class.getProtectionDomain().getCodeSource().getLocation().getPath()).getName();
Runtime.getRuntime().exec("java -jar " + jarname);
while(true) {
Objects.put(Double.valueOf(d), Double.valueOf(d));
d += 1.0D;