Skip to content

Instantly share code, notes, and snippets.

View cgutierrez's full-sized avatar

Chris Gutierrez cgutierrez

View GitHub Profile
@trinhtanloc789
trinhtanloc789 / index.html
Created November 1, 2019 12:40
Swiper custom transition effect
<div class="swiper-container">
<div class="swiper-wrapper">
<div class="swiper-slide" style="background-image:url(https://picsum.photos/1920/1080?image=991)">
</div>
<div class="swiper-slide" style="background-image:url(https://picsum.photos/1920/1080?image=1081)">
</div>
<div class="swiper-slide" style="background-image:url(https://picsum.photos/1920/1080?image=1064)">
</div>
<div class="swiper-slide" style="background-image:url(https://picsum.photos/1920/1080?image=1000)">
</div>'
@jeffpamer
jeffpamer / encode.sh
Created March 16, 2018 19:38
Smooth Scrubbing Web Video FFMPEG Mega Command
ffmpeg -i input.mp4 -vcodec libx264 -pix_fmt yuv420p -profile:v baseline -level 3 -an -vf "scale=-1:1440, reverse" -preset veryslow -g 2 output.mp4
// -vcodec libx264 -pix_fmt yuv420p -profile:v baseline -level 3
// Encode for web with a good balance of browser compatibility and compression ratio
// -an
// Strip audio tracks
// -vf "scale=-1:1440, reverse"
// Scale video to 1440px wide, maintaining aspect ratio
@staltz
staltz / introrx.md
Last active July 22, 2024 09:31
The introduction to Reactive Programming you've been missing
@necolas
necolas / .htaccess
Created April 9, 2012 22:19
Simple, quick way to concatenate, minify, and version static files in a Wordpress theme
# Filename-based cache busting
# taken from https://github.com/h5bp/html5-boilerplate/
# This rewrites file names of the form `name.123456.js` to `name.js`
# so that the browser doesn't use the cached version when you have
# updated (but not manually renamed) the file.
<IfModule mod_rewrite.c>
Options +FollowSymlinks
RewriteEngine On
@erikh
erikh / hack.sh
Created March 31, 2012 07:02 — forked from DAddYE/hack.sh
OSX For Hackers
#!/usr/bin/env sh
##
# This is script with usefull tips taken from:
# https://github.com/mathiasbynens/dotfiles/blob/master/.osx
#
# install it:
# curl -sL https://raw.github.com/gist/2108403/hack.sh | sh
#
@luetkemj
luetkemj / wp-query-ref.php
Last active May 25, 2024 10:56
WP: Query $args
// This gist is now maintained on github at https://github.com/luetkemj/wp-query-ref
<?php
/**
* WordPress Query Comprehensive Reference
* Compiled by luetkemj - luetkemj.github.io
*
* CODEX: http://codex.wordpress.org/Class_Reference/WP_Query#Parameters
* Source: https://core.trac.wordpress.org/browser/tags/4.9.4/src/wp-includes/query.php
*/
@potatosalad
potatosalad / project-web-reload.conf
Created February 11, 2012 03:32
Upstart + Bluepill + Unicorn with hot restart
# /etc/init/project-web-reload.conf
pre-start script
initctl restart project-web
sleep 15
end script
exec /usr/local/rvm/bin/default_bluepill restart
@nateabele
nateabele / routes.php
Last active June 16, 2017 13:05
Lithium continuation route examples
<?php
/**
* Continuation routing examples. Handles URLs in the following forms:
*
* /posts
* /en/posts
* /admin/posts
* /admin/en/posts
* /admin/en/posts.json
* /admin/en/posts/4ef16ccc7f8b9aa331000064.json
@mehlah
mehlah / li3_errors.php
Created December 18, 2011 17:17
Lithium Error handler
<?php
use lithium\core\ErrorHandler;
use lithium\action\Response;
use lithium\net\http\Media;
use lithium\analysis\Debugger;
use lithium\analysis\Logger;
use lithium\core\Environment;
/**
@osteslag
osteslag / version.sh
Created July 18, 2011 12:45
Script for managing build and version numbers using git and agvtool. See link in comments below.
#!/bin/sh
# Script for managing build and version numbers using git and agvtool.
# Change log:
# v1.0 18-Jul-11 First public release.
# v1.1 29-Sep-12 Launch git, agvtool via xcrun.
version() {