Skip to content

Instantly share code, notes, and snippets.

View gpessia's full-sized avatar
🏠
Working from home

gpessia gpessia

🏠
Working from home
View GitHub Profile
@gpessia
gpessia / wget.sh
Created August 14, 2020 11:14 — forked from crittermike/wget.sh
Download an entire website with wget, along with assets.
# One liner
wget --recursive --page-requisites --adjust-extension --span-hosts --convert-links --restrict-file-names=windows --domains yoursite.com --no-parent yoursite.com
# Explained
wget \
--recursive \ # Download the whole site.
--page-requisites \ # Get all assets/elements (CSS/JS/images).
--adjust-extension \ # Save files with .html on the end.
--span-hosts \ # Include necessary assets from offsite as well.
--convert-links \ # Update links to still work in the static version.
@gpessia
gpessia / Pok3r-keybinds.ahk
Created July 17, 2018 10:57 — forked from a-chen/Pok3r-keybinds.ahk
Pok3r keybinds including media and volume controls
#CommentFlag //
#InstallKeybdHook
// Original Author: Jarvis Prestidge
// Enhanced by: Andrew Chen
// =========================
// Pok3r Layout Marcos
// =========================
// Includes Media Keys (Previous|Q, Play/Pause|W, Next|E)
@gpessia
gpessia / generate-articles.py
Created July 14, 2018 09:57 — forked from jaden/generate-articles.py
A script that generates 5000 test posts for Hugo benchmarks
# Create specified number of articles for Hugo benchmarks
from datetime import datetime
import random
import string
from sys import argv
def generateWord():
length = random.randint(1, 10)
word = ''.join(random.choice(string.letters) for _ in range(length))
@gpessia
gpessia / index.html
Created May 10, 2017 15:36 — forked from liuyanghejerry/index.html
Modern index file in 2017
<!DOCTYPE html>
<html prefix="og: http://ogp.me/ns#">
<head>
<!-- content-type, which overrides http equivalent header. Because of charset, this meta should be set at first. -->
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<!-- Overrides http equivalent header. This tells IE to use the most updated engine. -->
<meta http-equiv="X-UA-Compatible" content="IE=Edge">
<!-- Tells crawlers how to crawl this page, and the role of this page. https://developer.mozilla.org/en-US/docs/Web/HTML/Element/meta -->
<meta name="robots" content="index, follow">
@gpessia
gpessia / .bash_profile
Created March 24, 2017 14:45 — forked from natelandau/.bash_profile
Mac OSX Bash Profile
# ---------------------------------------------------------------------------
#
# Description: This file holds all my BASH configurations and aliases
#
# Sections:
# 1. Environment Configuration
# 2. Make Terminal Better (remapping defaults and adding functionality)
# 3. File and Folder Management
# 4. Searching
# 5. Process Management
@gpessia
gpessia / .gitignore
Created February 2, 2017 09:20 — forked from octocat/.gitignore
Some common .gitignore configurations
# Compiled source #
###################
*.com
*.class
*.dll
*.exe
*.o
*.so
# Packages #
@gpessia
gpessia / Gulpfile.js
Created August 1, 2016 15:39 — forked from 0x1ad2/Gulpfile.js
My gulpfile example for How to enhance your front-end development workflow using Gulp
/*
* 0x1ad2 base Gulp.js file
* https://twitter.com/0x1ad2
*/
/*
* Define plugins
*/
var gulp = require('gulp');
var $ = require('gulp-load-plugins')();
@gpessia
gpessia / gist:67e10664b3a32b5d0367
Created January 20, 2016 10:13 — forked from benoitboucart/gist:f80090c87fa97f4e4098
How to use Jekyll with Gulp
/**
* For more information see this tutorial: http://blog.webbb.be/use-jekyll-with-gulp/
*
* Libs import
* --> How to install? npm install --save-dev gulp-minify-html
* @type {[type]}
*/
var gulp = require('gulp'),
path = require('path'),
@gpessia
gpessia / dummy-gene.html
Last active August 29, 2015 14:26 — forked from peace098beat/dummy-gene.html
ダミージェネレータ | unsplash.it
<a href="https://unsplash.it/">dummy generator<a/>
<img src="https://unsplash.it/200/300" alt="...">
<img src="https://unsplash.it/200/300?random" alt="...">
<img src="https://unsplash.it/200/300/list" alt="...">
<img src="https://unsplash.it/200/300?image=0" alt="...">
<img src="https://unsplash.it/200/300?blur" alt="...">
<img src="https://unsplash.it/200/300?gravity=east" alt="...">
<img src="https://unsplash.it/200/300?gravity=north" alt="...">
<img src="https://unsplash.it/200/300?gravity=south" alt="...">
@gpessia
gpessia / unsplash.sh
Last active August 29, 2015 14:26 — forked from chrismdp/unsplash.sh
Script to grab one of the 10 more recent images from Unsplash, and tint and blur it for use as an iTerm background using Solarized Dark
#!/bin/bash
# NOTE: requires ImageMagick
# NOTE: will tint to the Solarized Dark default background scheme, as the iTerm background blend option didn't lower the contrast enough for me
# NOTE: Optimised for a 1280x800 point screen (my 13" Retina MBP)
set -e
index=$[ 1 + $[ RANDOM % 10 ]]
img=`curl https://unsplash.com/rss/ | xmllint --xpath '/rss/channel/item['$index']/image/url/text()' -`
curl "$img" > ~/unsplash-latest.jpg &&