Skip to content

Instantly share code, notes, and snippets.

View stanosmith's full-sized avatar
☯️
👽

Stanley Smith stanosmith

☯️
👽
View GitHub Profile
@stanosmith
stanosmith / fix-postgresql-brew-service-fails-to-start.md
Created May 26, 2022 14:12
Sometimes the Postgresql Brew service isn't shut down correctly, due to a hard boot or OS crash, and the process id file (postmaster.pid) doesn't get removed.
  1. Remove the old postmaster.pid file:
trash /usr/local/var/postgres/postmaster.pid
# or rm /usr/local/var/postgres/postmaster.pid
  1. Restart the postgresql service:
brew services restart postgresql

Keybase proof

I hereby claim:

  • I am stanosmith on github.
  • I am stanosmith (https://keybase.io/stanosmith) on keybase.
  • I have a public key ASAd_tE4rh1KKUzFRrrPQBaLQy14cu5hWjHIh7Y2N4FugQo

To claim this, I am signing this object:

@stanosmith
stanosmith / .zshrc
Last active October 8, 2019 05:10
Custom iTerm2 Zsh Config
# Make sure you don't have this already
test -e "${HOME}/.iterm2_shell_integration.zsh" && source "${HOME}/.iterm2_shell_integration.zsh"
#
# Custom Status Bar Variables
#
iterm2_print_user_vars() {
# extend this to add whatever
# you want to have printed out in the status bar
iterm2_set_user_var nodeVersion $(node -v)
@stanosmith
stanosmith / gist:bedb996ea107d2ec69011d71f2ca16fa
Created January 7, 2019 18:40 — forked from chuckwagoncomputing/gist:4234127
pbcopy ssh public key to your clipboard
#pbcopy < ~/.ssh/id_rsa.pub
#or
cat ~/.ssh/id_rsa.pub | pbcopy
@stanosmith
stanosmith / .prettierrc
Created December 14, 2018 15:03
Default Prettier config
{
"singleQuote": true,
"trailingComma": "all",
"overrides": [
{
"files": ["*.scss"],
"options": { "singleQuote": false }
},
{
"files": ".prettierrc",
  1. Log out of and quit Skype for Business
  2. Go to Finder
  3. Press Command+Shift+G or click Go > Go to Folder
  4. Type ~/library and press Return
  5. Delete the following bold files:
    • Containers > com.microsoft.SkypeForBusiness
    • Internet Plug-Ins > MeetingJoinPlugin.plugin
    • Logs > LwaTracing
    • Saved Application State > com.microsoft.SkypeForBusiness.savedState
  • Preferences > com.microsoft.skypeforbusiness.plugin.plist
@stanosmith
stanosmith / yin-yang.css
Created October 11, 2018 23:26
Yin Yang by Alexander Futekov
/* More shapes: https://css-tricks.com/the-shapes-of-css */
/* Yin-Yang by Alexander Futekov */
#yin-yang {
width: 96px;
box-sizing: content-box;
height: 48px;
background: #eee;
border-color: red;
@stanosmith
stanosmith / box-sizing.scss
Created June 14, 2018 21:55
This reset gives you more flexibility than its predecessors — you can use content-box or padding-box (where supported) at will, without worrying about a universal selector overriding your CSS. We went into more depth on this technique and the reasoning behind it in "Inheriting box-sizing Probably Slightly Better Best Practice". One potential gri…
// Universal Box Sizing with Inheritance
// via: https://css-tricks.com/box-sizing/#article-header-id-6
html {
box-sizing: border-box;
}
*, *:before, *:after {
box-sizing: inherit;
}
@stanosmith
stanosmith / flexgrid.scss
Created June 14, 2018 19:12 — forked from RomanHargrave/flexgrid.scss
Tiny SCSS Flexbox Grid
/*
* Flexbox grid SCSS library
* Author: Roman Hargrave
* License: ASL 2.0
* The smallest grid system ever designed?
* */
@mixin flex-grid($classname: 'flexg', $columns: 16, $gutter: 0, $col-gutter: 10px) {
$column_name-format: #{$classname}-c-;
// Gradients
// Horizontal gradient, from left to right
//
// Creates two color stops, start and end, by specifying a color and position for each color stop.
// Color stops are not available in IE9 and below.
@mixin gradient-horizontal($start-color: #555, $end-color: #333, $start-percent: 0%, $end-percent: 100%) {
background-image: -webkit-linear-gradient(left, $start-color $start-percent, $end-color $end-percent); // Safari 5.1-6, Chrome 10+