Skip to content

Instantly share code, notes, and snippets.

View outofrange's full-sized avatar

Markus Möslinger outofrange

View GitHub Profile
@outofrange
outofrange / opencast.log
Last active January 16, 2020 07:03
Opencast startup failure - Sonatype moved to https (https://github.com/opencast/opencast/issues/1356)
Run opencast_tz_set
Run opencast_main_init
Setting timezone to Europe/Vienna
No custom config found
Run opencast_main_check
Run opencast_opencast_check
Run opencast_activemq_check
Run opencast_mysql_check
Run opencast_db_check
Run opencast_main_configure
@outofrange
outofrange / scrollDashboard.user.js
Created July 7, 2017 10:08
Chromish user script for scrolling Visual Studio Dashboards (can be used in conjunction with revolver plugins and Great Suspender or something like that)
// ==UserScript==
// @match https://*.visualstudio.com/*
// ==/UserScript==
!function(a,b){"use strict";"object"==typeof module&&"object"==typeof module.exports?module.exports=a.document?b(a,!0):function(a){if(!a.document)throw new Error("jQuery requires a window with a document");return b(a)}:b(a)}("undefined"!=typeof window?window:this,function(a,b){"use strict";var c=[],d=a.document,e=Object.getPrototypeOf,f=c.slice,g=c.concat,h=c.push,i=c.indexOf,j={},k=j.toString,l=j.hasOwnProperty,m=l.toString,n=m.call(Object),o={};function p(a,b){b=b||d;var c=b.createElement("script");c.text=a,b.head.appendChild(c).parentNode.removeChild(c)}var q="3.2.1",r=function(a,b){return new r.fn.init(a,b)},s=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,t=/^-ms-/,u=/-([a-z])/g,v=function(a,b){return b.toUpperCase()};r.fn=r.prototype={jquery:q,constructor:r,length:0,toArray:function(){return f.call(this)},get:function(a){return null==a?f.call(this):a<0?this[a+this.length]:this[a]},pushStack:function(a){var b=r.merge(this.constructor(),a)
@outofrange
outofrange / SendKeysBug.java
Created July 17, 2015 10:41
SSCCE for a potential Selenium bug: sendKeys() doesn't send keys (https://github.com/SeleniumHQ/selenium/issues/805)
package repro;
import org.openqa.selenium.By;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.WebElement;
import org.openqa.selenium.ie.InternetExplorerDriver;
import org.openqa.selenium.ie.InternetExplorerDriverService;
import org.openqa.selenium.remote.DesiredCapabilities;
public class SendKeysBug {
@outofrange
outofrange / StateMachine.java
Last active August 29, 2015 14:22
State Machine
package example;
import com.google.common.collect.Table;
import org.apache.log4j.Logger;
import java.util.*;
import java.util.stream.Collectors;
/**
* An implementation of a state machine able to choose the shortest path between two states.
@outofrange
outofrange / TimeConverter.java
Last active August 29, 2015 14:21
TimeConverter - converts Strings like "11w8d12h3m12s49ms" into milliseconds
package org.outofrange.timeconverter;
import java.util.ArrayList;
import java.util.List;
import java.util.concurrent.TimeUnit;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
public class TimeConverter {
private static final Pattern PATTERN = Pattern.compile("(\\d+)([A-Za-z]+)");
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<d:devices xmlns:d="http://schemas.android.com/sdk/devices/2" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<d:device>
<d:name>Samsung Tab</d:name>
<d:manufacturer>User</d:manufacturer>
<d:meta/>
<d:hardware>
<d:screen>
<d:screen-size>xlarge</d:screen-size>
<d:diagonal-length>8.00</d:diagonal-length>