Skip to content

Instantly share code, notes, and snippets.

View chaoslogick's full-sized avatar
👻
localghost

mpg chaoslogick

👻
localghost
View GitHub Profile
@chaoslogick
chaoslogick / setup.sh
Last active October 26, 2018 15:54
BASH: Personal setup.sh for OSX
#!/bin/bash
# Alot of these configs have been taken from the various places
# on the web
# Set the colors you can use
black='\033[0;30m'
white='\033[0;37m'
red='\033[0;31m'
green='\033[0;32m'
@chaoslogick
chaoslogick / .profile
Last active November 29, 2017 16:34
BASH: Personal .bashrc/.profile
#-------------------------------------------------
# global definitions
#-------------------------------------------------
# if not running interactively, don't do anything
[ -z "$PS1" ] && return
# don't put duplicate lines in the history. See bash(1) for more options
# or force ignoredups and ignorespace
export HISTCONTROL=ignoredups:ignorespace
@chaoslogick
chaoslogick / .gitconfig
Last active October 27, 2017 16:58
GIT: .gitconfig
[user]
name = Michael Perry Goodman
email = [redacted]
[filter "lfs"]
clean = git lfs clean %f
smudge = git lfs smudge %f
required = true
[core]
@chaoslogick
chaoslogick / tree.sh
Created January 14, 2016 18:48
BASH: Create matrix for Y Tree ASCII shape
#!/bin/bash
read n;
declare -A matrix
num_rows=63
num_columns=100
for ((i=1;i<=num_rows;i++)) do
for ((j=1;j<=num_columns;j++)) do
matrix[$i,$j]="_";
done
@chaoslogick
chaoslogick / bg_random.js
Created January 14, 2016 18:50
JS: Randomize DOM BG color
function changeBGColor() {
document.bgColor = document.colorChange.text.value;
document.colorChange.colorValue.value = '';
}
function randomBG() {
var h1 = new Array('0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'A', 'B', 'C', 'D', 'E', 'F');
var h2 = new Array('0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'A', 'B', 'C', 'D', 'E', 'F');
var h3 = new Array('0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'A', 'B', 'C', 'D', 'E', 'F');
var h4 = new Array('0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'A', 'B', 'C', 'D', 'E', 'F');
var h5 = new Array('0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'A', 'B', 'C', 'D', 'E', 'F');
@chaoslogick
chaoslogick / pow.dev
Last active March 2, 2016 20:11
POW: pow.dev
server {
listen 443 ssl;
server_name *.dev;
index index.html index.htm;
### SSL log files ###
access_log /usr/local/etc/nginx/logs/pow.dev-ssl-access.log;
error_log /usr/local/etc/nginx/logs/pow.dev-ssl-error.log;
@chaoslogick
chaoslogick / github-cloneall.sh
Created July 23, 2016 00:43
BASH: Clone all user's github repos
#!/bin/bash
if [ -z "$1" ]
then
echo "No arguments supplied"
else
curl -u michaelperrygoodman -s https://api.github.com/users/$1/repos?per_page=200 | ruby -rubygems -e 'require "json"; JSON.load(STDIN.read).each { |repo| %x[git clone #{repo["ssh_url"]} ]}'
fi
@chaoslogick
chaoslogick / slack-dark-mode.js
Created October 11, 2017 14:52
SLACK: dark mode [append to 'app.asar.unpacked/src/static/ssb-interop.js']
document.addEventListener('DOMContentLoaded', function() {
$.ajax({
url: 'https://cdn.rawgit.com/laCour/slack-night-mode/master/css/raw/black.css',
success: function(css) {
$("<style></style>").appendTo('head').html(css);
}
});
});
@chaoslogick
chaoslogick / animation-behaviors.scss
Last active March 15, 2019 00:32
SCSS: animation behaviors
// animation behaviors
// -------------------
$cubic-bezier: cubic-bezier(0.4, 0.0, 0.2, 1);
@mixin cubic-bezier {
-webkit-transition: all 225ms cubic-bezier(0.4, 0.0, 0.2, 1);
transition: all 225ms cubic-bezier(0.4, 0.0, 0.2, 1);
}
@mixin transition($args...) {
-webkit-transition: $args;
@chaoslogick
chaoslogick / cloudSettings
Last active August 14, 2020 02:32
VSCODE: sync-settings
{"lastUpload":"2020-08-14T02:32:29.078Z","extensionVersion":"v3.4.3"}