Skip to content

Instantly share code, notes, and snippets.

Carlos Araya caraya

Block or report user

Report or block caraya

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@westonruter
westonruter / scripts-to-footer-exclude-amp.php
Last active Jan 18, 2020
Exclude all AMP scripts from being moved to the footer by the Scripts To Footer plugin. All AMP scripts have async anyway so they do not need to be moved to the footer for performance.
View scripts-to-footer-exclude-amp.php
@CodingDoug
CodingDoug / README.md
Last active Sep 19, 2019
Realtime Database triggers with Cloud Functions for Firebase - source
View README.md

Realtime Database triggers with Cloud Functions for Firebase - source

This gist contains the source code in my video series about Realtime Database triggers. You can watch the three parts here:

  1. Part 1 (intro, onCreate)
  2. Part 2 (onUpdate, infinite loops)
  3. Part 3 (onDelete, transactions)

index.ts contains the Cloud Functions code, and dialog.ts contains the script to run

@mrbar42
mrbar42 / README.md
Last active Jan 18, 2020
bash scripts to create VOD HLS stream with ffmpeg almighty (tested on Linux and OS X)
View README.md

running:

bash create-vod-hls.sh beach.mkv

will produce:

    beach/
      |- playlist.m3u8
      |- 360p.m3u8
@surma
surma / gist:bcad12c026c395b00a32
Last active Oct 23, 2016
Mac Setup Routine
View gist:bcad12c026c395b00a32
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
brew install caskroom/cask/brew-cask
brew cask install google-chrome
ln -sf ~/Applications/Google\ Chrome.app /Applications
brew cask install megasync
ln -s '/opt/homebrew-cask/Caskroom/megasync/latest/MEGAsync.app' '/Applications/MEGAsync.app'
brew cask install dropbox
brew cask install google-drive
brew cask install iterm2
brew cask install spectacle
@domenic
domenic / auto-deploy.md
Last active Dec 12, 2019
Auto-deploying built products to gh-pages with Travis
View auto-deploy.md

Auto-deploying built products to gh-pages with Travis

This is a set up for projects which want to check in only their source files, but have their gh-pages branch automatically updated with some compiled output every time they push.

Create a compile script

You want a script that does a local compile to e.g. an out/ directory. Let's call this compile.sh for our purposes, but for your project it might be npm build or gulp make-docs or anything similar.

The out/ directory should contain everything you want deployed to gh-pages. That almost always includes an index.html.

@NickBarreto
NickBarreto / iBooks popups which degrade nicely in other devices
Last active Feb 2, 2019
How to create popup footnotes in iBooks which degrade well for other EPUB3 readers
View iBooks popups which degrade nicely in other devices
The only requirements for popup footnotes in iBooks are:
* Ebook has to be an EPUB3
* epub:type "noteref" and "footnote"
So you can link to a totally separate document, as you normally would for endnotes,
but include the attributes so the <a> link behaves differently in iBooks, instead triggering the popup.
Original reference link would look something like this (in a file called ch001.html):
<a epub:type="noteref" href="footnote.html#note1">1</a></div>
@roman01la
roman01la / index.html
Created Jun 17, 2013
THREE.js scene setup with JSONLoader for OSM2WebGL demo
View index.html
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8">
</head>
<body>
<div class="viewport"></div>
<script src="//cdnjs.cloudflare.com/ajax/libs/three.js/r58/three.min.js"></script>
<script src="//threejs.org/examples/js/controls/OrbitControls.js"></script>
@benfrain
benfrain / _media32.scss
Last active Nov 26, 2019
A Sass 3.2 mixin for dealing with Media Queries
View _media32.scss
// Here are some variables, then a mixin and then an application of the mixin - this will only compile using Sass 3.2
//variables
$XS: 12.5em; // 200px;
$S: 18.75em; // 300px
$SM: 35em; // 560px
$M: 47.5em; // 760px
$L: 63em; // 1008px
$XL: 110em; // 1760px
$XXL: 180em; // 2880px
@adactio
adactio / lettering.html
Created Jan 26, 2012
A quick'n'dirty way of doing some lettering.js stuff without jQuery.
View lettering.html
<!DOCTYPE html>
<html lang="en">
<head>
<title>Test</title>
<style>
.slogan span:nth-child(odd) {
color: red;
}
</style>
</head>
@alderete
alderete / my_looper-no_comments.php
Created Feb 4, 2011
A starter template for the Custom Loop API in the Thesis theme for WordPress.
View my_looper-no_comments.php
<?php
// Source and explanation of this file:
// http://aldosoft.com/blog/2011/01/thesis-custom-loop-template/
class my_looper extends thesis_custom_loop {
function home() {
thesis_loop::home();
}
You can’t perform that action at this time.