Skip to content

Instantly share code, notes, and snippets.

View Falieson's full-sized avatar
:shipit:

Florian Mettetal Falieson

:shipit:
View GitHub Profile
@Falieson
Falieson / getContrastText.js
Created February 14, 2019 22:59
material-ui getContrastText()
// tslint:disable
// MUI getContrastText
// REF: https://github.com/mui-org/material-ui/blob/ec37e2bb3c904d9552fa819425ee1eef72914996/packages/material-ui/src/styles/createPalette.js#L104
import * as warning from './node_modules/warning/warning.js';
export default function getContrastText({
background,
contrastThreshold,
dark,
@Falieson
Falieson / keys.sh
Last active September 13, 2022 21:40
Fluxbox Config
## KEYS
# Mod1 alt
# Mod4 win
# Control ctrl
# exit fluxbox
Control Mod1 Delete :Exit
# click on the desktop to get menus
OnDesktop Mouse1 :HideMenus
@Falieson
Falieson / bind2.js
Last active June 25, 2018 02:21
js impl of bind
// tslint:disable no-any
export default function bind2(this: any, that: any) {
const f = this // tslint:disable-line no-this-assignment
const initialArgs = Array.prototype.slice.call(arguments, 1)
return (finalArgs: any[]) => f.apply(that, [...initialArgs, ...finalArgs])
}
@Falieson
Falieson / extensions.list
Last active April 17, 2019 13:24
vscode settings, extensions
# replaced with tgr-extension-pack, listed here:
# https://github.com/TGRstack/vscode-extensions/blob/master/package.json#L34
@Falieson
Falieson / .zshrc
Created June 18, 2018 18:46
Linux Antigen .zshrc Config file
# Load NVM
export NVM_DIR="$(realpath $HOME/.nvm)"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion
# Linux antigen file
source /usr/share/zsh-antigen/antigen.zsh
# Load the oh-my-zsh's library.
antigen use oh-my-zsh
@Falieson
Falieson / tgr_jsutil_2.05.js
Created June 9, 2018 01:56
S2. F05. standard-version (ARTICLE: JS/TS-Module Utilities (Part 2/4))
// package-scripts.js, partial
const git = {
tags: {
push: 'git push --follow-tags origin master',
deleteAllLocally: "git tag -d `git tag | grep -E '.'`",
}
}
const release = {
@Falieson
Falieson / tgr_jsutil_2.04.js
Last active June 15, 2018 20:19
S2. F04. nps shortcuts (ARTICLE: JS/TS-Module Utilities (Part 2/4))
// package-scripts.js
const scripts = {
build,
commit,
default: start.default,
scrub,
start,
test: 'echo "Error: no test specified" && exit 1',
}
@Falieson
Falieson / tgr_jsutil_2.03.js
Created June 8, 2018 23:18
S2. F03. nps w/ series, rimraf (ARTICLE: JS/TS-Module Utilities (Part 2/4))
/** Available scripts (camel or kebab case accepted)
* like `nps` or a series like `nps build start.build`
* for more info `nps help build`
*
* build - nps commit.pre && nps build.ts
* build.ts - nps scrub.build && nps build.ts.tsc
* build.ts.tsc - tsc
* commit.pre - nps commit.pre.saveFixes
* commit.pre.saveFixes - git add .
* commit.zen - git-cz
@Falieson
Falieson / tgr_jsutil_2.02.js
Created June 8, 2018 22:36
S2. F02. package-scripts init (ARTICLE: JS/TS-Module Utilities (Part 2/4))
module.exports = {
scripts: {
build: 'rimraf dist/ && tsc',
commit: {
default: 'git-cz',
retry: 'git-cz --retry',
noverify: 'git-cz --no-verify'
},
default: {
build: 'node dist/index.js',
@Falieson
Falieson / tgr_tsmod_6.02a.json
Created May 31, 2018 22:14
S6. F02. write and execute consumer (ARTICLE: TS-Module w/ Declarations (Part 1/4))
/** TS-Module w/ Declarations (Part 1/4)
* http://TGRstack.com/#ts-module_articles_part-1
* ./index.ts (Section 6. Figure 02.A.)
**/
import Hello from '2018-ts-module'
console.log(Hello('Aloha', 'Jupiter'))