Skip to content

Instantly share code, notes, and snippets.

View joewils's full-sized avatar

Joe Wilson joewils

View GitHub Profile
@dhh
dhh / linux-setup.sh
Last active May 4, 2024 07:05
linux-setup.sh
# CLI
sudo apt update -y
sudo apt install -y \
git curl \
docker.io docker-buildx \
build-essential pkg-config autoconf bison rustc cargo clang \
libssl-dev libreadline-dev zlib1g-dev libyaml-dev libreadline-dev libncurses5-dev libffi-dev libgdbm-dev libjemalloc2 \
libvips imagemagick libmagickwand-dev mupdf mupdf-tools \
redis-tools sqlite3 libsqlite3-0 libmysqlclient-dev \
rbenv apache2-utils
@IanColdwater
IanColdwater / twittermute.txt
Last active April 22, 2024 17:26
Here are some terms to mute on Twitter to clean your timeline up a bit.
Mute these words in your settings here: https://twitter.com/settings/muted_keywords
ActivityTweet
generic_activity_highlights
generic_activity_momentsbreaking
RankedOrganicTweet
suggest_activity
suggest_activity_feed
suggest_activity_highlights
suggest_activity_tweet
@alirobe
alirobe / reclaimWindows10.ps1
Last active April 26, 2024 17:59
This Windows 10 Setup Script turns off a bunch of unnecessary Windows 10 telemetery, bloatware, & privacy things. Not guaranteed to catch everything. Review and tweak before running. Reboot after running. Scripts for reversing are included and commented. Fork of https://github.com/Disassembler0/Win10-Initial-Setup-Script (different defaults). N.…
###
###
### UPDATE: For Win 11, I recommend using this tool in place of this script:
### https://christitus.com/windows-tool/
### https://github.com/ChrisTitusTech/winutil
### https://www.youtube.com/watch?v=6UQZ5oQg8XA
### iwr -useb https://christitus.com/win | iex
###
###
@oojikoo-gist
oojikoo-gist / random_location_circle.rb
Created October 14, 2015 19:26
ruby: random_location_circle
def random_location_from(center_lat, center_lng, distance)
radius = distance
radiusInDegrees=radius/111000.to_f
r = radiusInDegrees
origin_x = center_lat
origin_y = center_lng
u = rand(0.00..1.00)
v = rand(0.00..1.00)
@imjasonh
imjasonh / markdown.css
Last active February 12, 2024 17:18
Render Markdown as unrendered Markdown (see http://jsbin.com/huwosomawo)
* {
font-size: 12pt;
font-family: monospace;
font-weight: normal;
font-style: normal;
text-decoration: none;
color: black;
cursor: default;
}
@mattgbrady
mattgbrady / fvschedule.rb
Created March 13, 2014 20:44
Excel fvschedule function in Ruby
def fvschedule(principal=1.0, schedule)
total_return = principal
schedule.each{|x| total_return*=(1+x)}
return total_return
end
def annualized_return(period, schedule)
ann_return = 0
schedule_length = schedule.length
if schedule_length/Float(period) > 1
@lelandbatey
lelandbatey / whiteboardCleaner.md
Last active April 25, 2024 02:01
Whiteboard Picture Cleaner - Shell one-liner/script to clean up and beautify photos of whiteboards!

Description

This simple script will take a picture of a whiteboard and use parts of the ImageMagick library with sane defaults to clean it up tremendously.

The script is here:

#!/bin/bash
convert "$1" -morphology Convolve DoG:15,100,0 -negate -normalize -blur 0x1 -channel RBG -level 60%,91%,0.1 "$2"

Results

@kanmeiban
kanmeiban / Why Recruiters Are Universally Hated
Created November 22, 2013 20:22
Dealing with recruiters is as nice as dealing with faecal matter. You'd better flush as soon as possible.
Why Recruiters Are Universally Hated
On 14. January 2013 I was invited for a job interview in London by Mr Ethan James of recruiting company
TestDriven IT Group on behalf of his client, a start-up looking for Ruby on Rails developer. Mr Ethan
James proposed I should fly with a low cost jet to get full reimbursement on my tickets. Hower I prefer
rail and sea transport to air travel beacause of their smaller environmental footprint so we agreed that
TestDriven IT Group will cover only half of my travel costs. The interview went well, I wasn’t hired so
I traveled back to my home country through the snow covered Europe, sent a scan of the tickets to the
recruiters upon my arrival and waited for the reimbursement to come.
@philfreo
philfreo / gist:7257723
Created October 31, 2013 21:44
Facebook Perl source code from 2005. When browsing around thefacebook.com in 2005 the server spit out some server-side source code rather than running it. I believe this was for their old graph feature that let you visualize the graph between all your friends. The filename is `mygraph.svgz` and contains some gems such as a commented out "zuck" d…
#!/usr/bin/perl
use Mysql;
use strict;
use vars qw($school_name);
use vars qw($pass);
require "./cgi-lib.pl";
@chengyin
chengyin / linkedout.js
Last active July 11, 2021 15:23
Unsubscribe all LinkedIn email in "one click". For an easier to use version, you can check out the bookmarklet: http://chengyin.github.io/linkedin-unsubscribed/
// 1. Go to page https://www.linkedin.com/settings/email-frequency
// 2. You may need to login
// 3. Open JS console
// ([How to?](http://webmasters.stackexchange.com/questions/8525/how-to-open-the-javascript-console-in-different-browsers))
// 4. Copy the following code in and execute
// 5. No more emails
//
// Bookmarklet version:
// http://chengyin.github.io/linkedin-unsubscribed/