Skip to content

Instantly share code, notes, and snippets.

View egoens's full-sized avatar

Erik Goens egoens

View GitHub Profile
@fnky
fnky / variable-fonts.md
Last active April 12, 2024 18:12
Awesome Variable Fonts

Awesome Variable Fonts

A list of open source and free* variable fonts.

* Some fonts may require a license to be used for commerical use.

Open Source

@gregorynicholas
gregorynicholas / Installation.md
Created October 3, 2019 22:36 — forked from albertbori/Installation.md
Automatically disable Wifi when an Ethernet connection (cable) is plugged in on a Mac

Overview

This is a bash script that will automatically turn your wifi off if you connect your computer to an ethernet connection and turn wifi back on when you unplug your ethernet cable/adapter. If you decide to turn wifi on for whatever reason, it will remember that choice. This was improvised from this mac hint to work with Yosemite, and without hard-coding the adapter names. It's supposed to support growl, but I didn't check that part. I did, however, add OSX notification center support. Feel free to fork and fix any issues you encounter.

Most the credit for these changes go to Dave Holland.

Requirements

  • Mac OSX 10+
  • Administrator privileges
/*
* This script fetches all color styles from a Figma team/document.
*
* Dependencies:
*
* - node-fetch
*
* Due to a limitation in the Figma /styles endpoint, we need to use a
* document for actually using the colors in a color grid 🙄That's why
* we're both fetching from /styles and /files below.
@egoens
egoens / postgres cheatsheet.md
Last active January 12, 2018 16:44 — forked from apolloclark/postgres cheatsheet.md
postgres cheatsheet

Postgres Cheatsheet

This is a collection of the most common commands I run while administering Postgres databases. The variables shown between the open and closed tags, "<" and ">", should be replaced with a name you choose. Postgres has multiple shortcut functions, starting with a forward slash, "". Any SQL command that is not a shortcut, must end with a semicolon, ";". You can use the keyboard UP and DOWN keys to scroll the history of previous commands you've run.

Setup

installation, Ubuntu

http://www.postgresql.org/download/linux/ubuntu/ https://help.ubuntu.com/community/PostgreSQL

@egoens
egoens / ssh-add.md
Last active March 18, 2024 19:13
Use this if ssh key keeps asking for password
@egoens
egoens / create_react_prototype.rb
Last active September 7, 2017 14:49
Create a new ReactJS Prototype (Storybook + Styled Components)
# Creates a new `create-react-app` prototype in the current directory
# this is a very basic installation whose major purpose is creating
# a storybook (http://getstorybook.io) for quick component creation
# and iteration. These components are intended to be styled with
# `styled-components` (https://github.com/styled-components/styled-components)
#
# usage:
# ruby create_prototype.rb
#
# map as an alias in your environment file (ex: ~/.zshrc) to run from any directory
@hopsoft
hopsoft / example_job.rb
Last active September 9, 2022 06:00
Render views outside of the standard request context (i.e. ActiveJob) with Devise/Warden
class ExampleJob < ApplicationJob
queue_as :default
def perform(user)
# do some work
# HACK: get around limitations in devise/warden when rendering
# views outside the context of a formal http request
renderer = ::ApplicationController.renderer.new
renderer_env = renderer.instance_eval { @env }
@kevinelliott
kevinelliott / 1-macOS-10.12-sierra-setup.md
Last active February 5, 2024 07:22
macOS 10.12 Sierra Setup

macOS 10.12 Sierra Setup

Custom recipe to get macOS 10.12 Sierra running from scratch, setup applications and developer environment. This is very similar (and currently mostly the same) as my 10.11 El Capitan setup recipe and 10.10 Yosemite setup recipe. I am currently tweaking this for 10.12 Sierra and expect to refine this gist over the next few weeks.

I use this gist to keep track of the important software and steps required to have a functioning system after a semi-annual fresh install. I generally reinstall each computer from scratch every 6 months, and I do not perform upgrades between releases.

This keeps the system performing at top speeds, clean of trojans, spyware, and ensures that I maintain good organizational practices for my content and backups. I highly recommend this.

You are encouraged to fork this and modify it to your heart's content to match your o

files:
/etc/nginx/conf.d/proxy.conf:
content: |
client_max_body_size 25M;
server_names_hash_bucket_size 128;
upstream backend {
server unix:///var/run/puma/my_app.sock;
}
@egoens
egoens / Readme.md
Last active May 9, 2016 19:21
Generate/Destory rails scaffolding

Requirements

Must create a docs folder and put models.yml inside this folder.