Skip to content

Instantly share code, notes, and snippets.

Max Kohler awesomephant

View GitHub Profile
View index.html
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Kat's cool websiteee</title>
<link rel="stylesheet" href="style.css">
</head>
<body>
<h1 class='name'>Kat Mcgrath</h1>
View kat.html
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>Document</title>
</head>
@awesomephant
awesomephant / bp.scss
Created May 26, 2019
Sass breakpoint mixin
View bp.scss
@mixin bp($point) {
@if $point==xl {
@media (min-width: 85rem) {
@content;
}
}
@else if $point==l {
@media (min-width: 70rem) {
@content;
}
View test.js
console.log('Hello World 123')
@awesomephant
awesomephant / mousemove.js
Last active Jan 24, 2019
Mousemove Optimized
View mousemove.js
var last_known_scroll_position = 0;
var ticking = false;
function doSomething(scroll_pos) {
// do something with the scroll position
}
window.addEventListener('mousemove', function(e) {
last_known_position = {
View parseSwitchboard.js
const fs = require('fs');
const path = require('path');
const parse = require('csv-parse/lib/sync');
const mkdirp = require('mkdirp');
const dataDir = './data/switchboard_conversations/';
const outputDir = './data/clean/';
let topics = fs.readdirSync(dataDir)
let data = [];
View gist:ac7c05bda60ab7bf8e3135f710cc2d4e
gm montage -tile 28x19 -background "black" -geometry 300x300+2+2 *.jpg grid.jpg
@awesomephant
awesomephant / wp-setup
Last active Apr 1, 2018
Install common WP plugins
View wp-setup
cd ap ; wp core update ; wp plugin update --all; wp theme update --all ; wp plugin delete hello ; wp plugin delete akismet ; wp plugin install custom-post-type-ui --activate ; wp plugin install timber-library --activate ; wp plugin install woocommerce --activate ; cd .. ; cd aside ; wp core update ; wp plugin update --all; wp theme update --all ; wp plugin delete hello ; wp plugin delete akismet ; wp plugin install custom-post-type-ui --activate ; wp plugin install timber-library --activate ; cd .. ; cd zwicker ; wp core update ; wp plugin update --all; wp theme update --all ; wp plugin delete hello ; wp plugin delete akismet ; wp plugin install custom-post-type-ui --activate ; wp plugin install timber-library --activate ; cd .. ; cd humboldt ; wp core update ; wp plugin update --all; wp theme update --all ; wp plugin delete hello ; wp plugin delete akismet ; wp plugin install custom-post-type-ui --activate ; wp plugin install timber-library --activate ; cd .. ; cd particitype ; wp core update ; wp plugin upd
View gist:52f07bb61c295daf50e2c0237875680e
sudo apt-get install git
sudo apt-get install curl
curl -sL https://deb.nodesource.com/setup_8.x | sudo -E bash -
sudo apt-get install -y nodejs
cd Documents/
https://github.com/awesomephant/sineMachine.git
View getRandomInt.js
const gra = function(min, max) {
return Math.random() * (max - min) + min;
}
const gri = function(min, max) {
return Math.floor(Math.random() * (max - min + 1)) + min;
}
You can’t perform that action at this time.