Skip to content

Instantly share code, notes, and snippets.

View ecoleman's full-sized avatar

Eric Coleman ecoleman

View GitHub Profile
@ecoleman
ecoleman / darkModeHandler.ts
Created May 5, 2020 22:41 — forked from hteumeuleu/darkModeHandler.ts
Outlook.com darkModeHandler
import ContentHandler from '../schema/ContentHandler';
import { transformElementForDarkMode, AlteredElement } from 'owa-dark-mode-utilities';
import {
ATTR_COLOR,
ATTR_BGCOLOR,
DATA_OG_STYLE_COLOR,
DATA_OG_ATTR_COLOR,
DATA_OG_STYLE_BACKGROUNDCOLOR,
DATA_OG_ATTR_BGCOLOR,
} from 'owa-content-colors';
Phoenix.set({
daemon: true,
openAtLogin: true,
})
var left = new Key('left', ['cmd', 'alt'], function() {
const parent = Screen.main().visibleFrame()
const win = Window.focused()
const frame = win.screen().frame()
! function(e) {
function t(o) {
if (n[o]) return n[o].exports;
var r = n[o] = {
exports: {},
id: o,
loaded: !1
};
return e[o].call(r.exports, r, r.exports, t), r.loaded = !0, r.exports
}
Apr 4 04:43:57 primeevil kernel: audit: type=1702 audit(1455292390.665:11): op=linkat ppid=27003 pid=27007 auid=4294967295 uid=1004 gid=1000 euid=1004 suid=1004 fsuid=1004 egid=1000 sgid=1000 fsgid=1000 tty=(none) ses=4294967295 comm="git" exe="/usr/bin/git" res=0
Apr 4 04:43:57 primeevil kernel: audit: type=1302 audit(1455292390.665:12): item=0 name="/srv/blank/projects/blankcms_com/app/files/source-cache/sandbox/.git/objects/pack/pack-6d44d632a872e6fa13445814ff48f327aa3107c5.pack" inode=2436251 dev=ca:00 mode=0100444 ouid=1001 ogid=1000 rdev=00:00 nametype=NORMAL
Apr 4 04:44:00 primeevil kernel: php[27010]: segfault at b3ba9b10 ip b3ba9b10 sp bfbc59cc error 14 in librt-2.18.so[b4a24000+7000]
Feb 12 15:53:14 primeevil systemd-coredump[27014]: Process 27010 (php) dumped core.
@ecoleman
ecoleman / marketing.html
Created August 17, 2015 20:52
Noticed dropbox including a script from `marketing.dropbox.com`, and this is what's inside:
<html>
<head>
<!--[if (gte IE 9) ]>
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<![endif]-->
<title>Dropbox</title>
<meta http-equiv="Content-Security-Policy" content="default-src https: 'unsafe-inline' 'unsafe-eval'; ">
</head>
<body>
<script>
@ecoleman
ecoleman / Makefile
Last active August 29, 2015 14:18 — forked from isaacs/Makefile
# Hello, and welcome to makefile basics.
#
# You will learn why `make` is so great, and why, despite its "weird" syntax,
# it is actually a highly expressive, efficient, and powerful way to build
# programs.
#
# Once you're done here, go to
# http://www.gnu.org/software/make/manual/make.html
# to learn SOOOO much more.
@ecoleman
ecoleman / eric-test.html
Created October 4, 2014 21:51
AngularJS Directive Callback Example
<button value="1">1</button>
<button value="2">2</button>
<button value="3">3</button>
<button value="4">4</button>
<button value="5">5</button>
// load the `gameState` param from localStorage and convert it from JSON to an object
var game = JSON.parse(localStorage.getItem("gameState"));
// after the above line, you can type `game` in your console to see what properties it has
// change the `game.stores.wood` param to 15
game.stores.wood = 15;
// re-encode the game state into json and update localStorage
localStorage.setItem("gameState", JSON.stringify(game));

Keybase proof

I hereby claim:

  • I am ecoleman on github.
  • I am ericcoleman (https://keybase.io/ericcoleman) on keybase.
  • I have a public key whose fingerprint is AA16 E9A5 3B87 22F8 F28C 620E C20D D3F9 AEC8 651D

To claim this, I am signing this object:

S.cfga({
"defaultToCurrentScreen": true,
"nudePercentOf": "screenSize",
"resizePercentOf": "screenSize"
});
S.bnda({
"down:ctrl;alt;cmd": S.op("move", {
"x": "screenOriginX",