Skip to content

Instantly share code, notes, and snippets.

View joonaspaakko's full-sized avatar
🍕
Pizza...

Joonas Pääkkö joonaspaakko

🍕
Pizza...
View GitHub Profile
@andrewlimaza
andrewlimaza / honeypot-example.php
Last active November 16, 2024 11:47
Simple honeypot for an HTML form using PHP
<?php
//check if form was sent
if($_POST){
$to = 'some@email.com';
$subject = 'Testing HoneyPot';
$header = "From: $name <$name>";
$name = $_POST['name'];
@jagrosh
jagrosh / WebhookTutorial.md
Last active September 19, 2024 03:24
Simple Webhook Tutorial (Twitter -> Discord)

Simple Webhook Tutorial

In this tutorial, I will be explaining how to set up a simple webhook to relay your tweets to a Discord channel

Step 1 - Register on Zapier

  1. Go to https://zapier.com/ and create an account (if you don't already have one).

Step 2 - Make a Discord Webhook

  1. Find the Discord channel in which you would like to send Tweets
@kevin-smets
kevin-smets / iterm2-solarized.md
Last active December 13, 2024 03:40
iTerm2 + Oh My Zsh + Solarized color scheme + Source Code Pro Powerline + Font Awesome + [Powerlevel10k] - (macOS)

Default

Default

Powerlevel10k

Powerlevel10k

@TomByrne
TomByrne / MultiExporter.jsx
Last active November 14, 2024 16:35
An Illustrator script for exporting layers and/or artboards into separate files (PNG8 / PNG24 / EPS / PDF / SVG / JPG / FXG).See http://www.tbyrne.org/export-illustrator-layers-to-svg-files
// MultiExporter.jsx
// Version 0.1
// Version 0.2 Adds PNG and EPS exports
// Version 0.3 Adds support for exporting at different resolutions
// Version 0.4 Adds support for SVG, changed EPS behaviour to minimise output filesize
// Version 0.5 Fixed cropping issues
// Version 0.6 Added inner padding mode to prevent circular bounds clipping
//
// Copyright 2013 Tom Byrne
// Comments or suggestions to tom@tbyrne.org
@grayghostvisuals
grayghostvisuals / validator.addMethod.passMatch.js
Created October 15, 2013 00:12
A simplistic way to make sure two password fields match using jQueryValidation (http://jqueryvalidation.org/validate) Using minlength, and a custom message.
jQuery.validator.addMethod( 'passwordMatch', function(value, element) {
// The two password inputs
var password = $("#register-password").val();
var confirmPassword = $("#register-pass-confirm").val();
// Check for equality with the password inputs
if (password != confirmPassword ) {
return false;
} else {
@tskaggs
tskaggs / OSX-Convert-MOV-GIF.md
Last active November 5, 2024 21:41
Creating GIFs from .MOV files in OSX using FFmpeg and ImageMagick

Convert MOV to GIF using FFmpeg and ImageMagick

I tried a few different techniques to make a GIF via command-line and the following gives me the best control of quality and size. Once you're all setup, you'll be pumping out GIFs in no time!

Preparation

Install FFmpeg

  • $ brew install ffmpeg [all your options]
    • Example: $ brew install ffmpeg --with-fdk-aac --with-ffplay --with-freetype --with-frei0r --with-libass --with-libvo-aacenc --with-libvorbis --with-libvpx --with-opencore-amr --with-openjpeg --with-opus --with-rtmpdump --with-schroedinger --with-speex --with-theora --with-tools

Install ImageMagick

require 'json'
require 'net/http'
# JSON parser tag, creating map for use in jekyll markdown
# Alex.Heneveld @ Cloudsoft Corp (remove spaces and add the .com)
# Released under APL 2.0
# usage: {% jsonball varname from TYPE PARAM %}
#
# where TYPE is one of {data,var,file,page}, described below
@GrahamWalters
GrahamWalters / gist:5848822
Created June 24, 2013 09:21
Reset QuickLook Thumbnail Cache: Open Terminal and run the following commands
sudo find /var/folders/ -name com.apple.QuickLook.thumbnailcache -type d
# Enter your password and hit enter (it will not display your password).
cd COPY-AND-PAST-THE-ABOVE-OUTPUT-HERE
cd ../
sudo mv com.apple.QuickLook.thumbnailcache com.apple.QuickLook.thumbnailcache-BACK
# Restart your computer.
### If anything goes wrong run the following:
sudo find /var/folders/ -name com.apple.QuickLook.thumbnailcache-BACK -type d
@cameronmcefee
cameronmcefee / ps-dev-references.md
Last active January 26, 2016 09:48
Here's a list of resources I provide people when they want to start looking into Photoshop development.

Sites and tools

Roughly ordered by functional (not skill level) simplicity, that is they go from simple (basic scripting) to complex (full Photoshop Extensions).

  • Photoshop Script reference - Start here for all your scripting needs. Check out the script listener plugin too. It outputs anything you do in Photoshop as Javascript.
  • Adobe Configurator - Build quick (but simple) panels. Basically GUI interface for scripts.
  • Adobe Photoshop Scripting and SDK forums. Somewhat helpful for scripting/extension building. Don't expect quick answers.
  • PS-Scripts - Another semi-helpful forum
  • Photoshop CS5 Panel Developer's Guide - Hard to find now. I don't think they made one for CS6, but it's still releveant for so