Skip to content

Instantly share code, notes, and snippets.

Avatar

Jared Rummler jaredrummler

View GitHub Profile
@jaredrummler
jaredrummler / bloomberg-futures.userscript.js
Created Mar 17, 2021
Use percent change when viewing futures on Bloomberg
View bloomberg-futures.userscript.js
// ==UserScript==
// @name Bloomberg Futures
// @namespace http://tampermonkey.net/
// @version 0.1
// @description Chage table content to use percents for futures
// @author Jared Rummler
// @match https://www.bloomberg.com/markets/stocks/futures
// @grant none
// ==/UserScript==
@jaredrummler
jaredrummler / TimberJava.xml
Created Feb 11, 2021 — forked from ericksli/TimberJava.xml
Timber Android Studio live template for Java and Kotlin #kotlin #android
View TimberJava.xml
<templateSet group="TimberJava">
<template name="timd" value="timber.log.Timber.d(&quot;$METHOD_NAME$: $content$&quot;);" description="Timber.d(String)" toReformat="true" toShortenFQNames="true">
<variable name="METHOD_NAME" expression="methodName()" defaultValue="" alwaysStopAt="false" />
<variable name="content" expression="" defaultValue="" alwaysStopAt="true" />
<context>
<option name="JAVA_STATEMENT" value="true" />
</context>
</template>
<template name="time" value="timber.log.Timber.e($exception$, &quot;$METHOD_NAME$: $content$&quot;);" description="Timber.e(Exception, String)" toReformat="true" toShortenFQNames="true">
<variable name="exception" expression="" defaultValue="e" alwaysStopAt="true" />
@jaredrummler
jaredrummler / instagram.json
Last active Nov 14, 2020
shields.io badges
View instagram.json
{
"schemaVersion": 1,
"label": "Instagram",
"message": "jaredrummler",
"color": "#c32aa3",
"namedLogo": "instagram",
"style": "social"
}
@jaredrummler
jaredrummler / IconView.kt
Created Oct 26, 2020 — forked from nickbutcher/IconView.kt
A prototype implementation of a shadow effect inspired by the Google Play Games app (https://play.google.com/store/apps/details?id=com.google.android.play.games).
View IconView.kt
/*
* Copyright 2017 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file
* except in compliance with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software distributed under the
* License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
View flutter-material-color-generator.md
MaterialColor createMaterialColor(Color color) {
  List strengths = <double>[.05];
  Map swatch = <int, Color>{};
  final int r = color.red, g = color.green, b = color.blue;

  for (int i = 1; i < 10; i++) {
    strengths.add(0.1 * i);
  }
  strengths.forEach((strength) {
@jaredrummler
jaredrummler / index.html
Created May 1, 2020
The handbook download animation
View index.html
<div class="container">
<div class="box box-1">
<div class="cover"><img src="https://s3-us-west-2.amazonaws.com/s.cdpn.io/945546/3433202-893bc9989a52eba0.png" alt=""></div>
<button><div></div></button>
</div>
<div class="box box-2">
<div class="cover"><img src="https://s3-us-west-2.amazonaws.com/s.cdpn.io/945546/3433202-964edcf0f07211b0.png" alt=""></div>
<button><div></div></button>
</div>
<div class="box box-3">
View Prefs.kt
/*
* Copyright (C) 2020 Jared Rummler
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
View MountPoint.kt
import java.io.File
import java.util.regex.Matcher
import java.util.regex.Pattern
fun String.toFile() = File(this)
operator fun Matcher.get(group: Int): String = group(group)!!
data class MountPoint(
@jaredrummler
jaredrummler / ffmpeg_frames.sh
Created Sep 23, 2019 — forked from loretoparisi/ffmpeg_frames.sh
Extract all frames from a movie using ffmpeg
View ffmpeg_frames.sh
# Output a single frame from the video into an image file:
ffmpeg -i input.mov -ss 00:00:14.435 -vframes 1 out.png
# Output one image every second, named out1.png, out2.png, out3.png, etc.
# The %01d dictates that the ordinal number of each output image will be formatted using 1 digits.
ffmpeg -i input.mov -vf fps=1 out%d.png
# Output one image every minute, named out001.jpg, out002.jpg, out003.jpg, etc.
# The %02d dictates that the ordinal number of each output image will be formatted using 2 digits.
ffmpeg -i input.mov -vf fps=1/60 out%02d.jpg
View REVERSE_GIF.md
gifsicle --unoptimize --explode original.gif && 
find . -iname "*\.gif\.*" | sort > frame_list.txt && 
find . -iname "*\.gif\.*" | sort -r >> frame_list.txt && 
cat frame_list.txt | xargs gifsicle > reversed.gif