Skip to content

Instantly share code, notes, and snippets.

View nemoDreamer's full-sized avatar
🔎
Working at SyncSketch.

Philip Blyth nemoDreamer

🔎
Working at SyncSketch.
View GitHub Profile
@nemoDreamer
nemoDreamer / palette.sh
Created August 28, 2023 16:54
Display ANSI palette in terminal
#!/usr/bin/env bash
NAMES=(Black Red Green Yellow Blue Magenta Cyan White)
CHAR="██ "
for i in {0..7}; do
CODE=$((i + 30))
BRIGHT=$((i + 90))
echo -n -e "${NAMES[$i]}\t"
@nemoDreamer
nemoDreamer / bare.css
Last active July 7, 2022 18:19
Markdown Preview / Print styles for use with VS Code's `markdown.styles` URLs
li {
color: red;
}
@nemoDreamer
nemoDreamer / crontab
Last active October 28, 2021 15:42
A constant reminder to sit up straight...
*/5 * * * * /<path-to>/bin/node ./<path-to>/sayPosture.js >/dev/null 2>&1
@nemoDreamer
nemoDreamer / README.md
Last active November 4, 2023 18:10
`React.cloneElement` vs. `Render Prop` pattern benchmarking

React.cloneElement vs. Render Prop pattern benchmarking

Run:

babel clone-element-vs-render-prop.jsx | node

Result:

@nemoDreamer
nemoDreamer / git-prune-branches.sh
Created October 13, 2017 18:38
Prune local and remote merged branches
#!env bash
# NOTE: based on
# https://coderwall.com/p/fkk2lw/bash-script-to-clean-up-obsolete-git-branches
# Changes made to first only remove branches you've checked out,
# then 2nd repo-wide check.
# also added human-readable output and prompts
# This has to be run from master
git checkout master
@nemoDreamer
nemoDreamer / styles.less
Created May 20, 2017 12:16
Subtle italics in Atom syntaxes
atom-text-editor.editor {
.syntax--punctuation.syntax--whitespace.syntax--comment.syntax--leading,
.syntax--source {
font-family: FiraCode-Retina; // https://github.com/tonsky/FiraCode
text-rendering: optimizeLegibility;
letter-spacing: 0;
}
.syntax--string.quoted,
.syntax--string.regexp {
atom-text-editor::shadow {
.source {
font-family: FiraCode-Retina;
text-rendering: optimizeLegibility;
}
.string.quoted,
.string.regexp {
-webkit-font-feature-settings: "liga" off, "calt" off;
}
@nemoDreamer
nemoDreamer / SassMeister-input.scss
Created June 16, 2015 14:45
Generated by SassMeister.com.
// ----
// libsass (v3.2.5)
// ----
$nav_light_color: white;
$nav_dark_color: black;
%base_nav_item {
color: darken($nav_light_color, 25);
@nemoDreamer
nemoDreamer / SassMeister-input.scss
Last active August 29, 2015 14:23
Generated by SassMeister.com.
// ----
// libsass (v3.2.5)
// ----
$nav_light_color: white;
$nav_dark_color: black;
%base_nav_item {
color: darken($nav_light_color, 25);
@nemoDreamer
nemoDreamer / SassMeister-input.scss
Created June 15, 2015 20:40
Generated by SassMeister.com.
// ----
// libsass (v3.2.5)
// ----
.base_nav_item {
display: -webkit-box;
display: -moz-box;
-webkit-box-orient: vertical;
-moz-box-orient: vertical;
-webkit-box-align: center;