This gist shows how to create a GIF screencast using only free OS X tools: QuickTime, ffmpeg, and gifsicle.
To capture the video (filesize: 19MB), using the free "QuickTime Player" application:
Sometimes you want to have a subdirectory on the master
branch be the root directory of a repository’s gh-pages
branch. This is useful for things like sites developed with Yeoman, or if you have a Jekyll site contained in the master
branch alongside the rest of your code.
For the sake of this example, let’s pretend the subfolder containing your site is named dist
.
Remove the dist
directory from the project’s .gitignore
file (it’s ignored by default by Yeoman).
EventEmitter = (require?("./EventEmitter") || Framer).EventEmitter | |
class AppStateMachine extends EventEmitter | |
constructor: -> | |
@states = [] | |
# Start the state machine with the document's hash, or the given route | |
start: (name) -> | |
@go if document.location.hash then document.location.hash[1..-1] else name |
# see https://github.com/reactjs/react-meteor | |
# and https://github.com/jhartma/meteor-cjsx | |
@IncludeTemplate = React.createClass | |
componentDidMount: () -> | |
componentRoot = React.findDOMNode(@) | |
parentNode = componentRoot.parentNode | |
parentNode.removeChild(componentRoot); | |
Blaze.render @props.template, parentNode |
Layer::isOverlapping = (targetLayer, offset = 0) -> | |
if @screenFrame.x + @width + offset >= targetLayer.screenFrame.x && | |
@screenFrame.x - offset <= targetLayer.screenFrame.x + targetLayer.width && | |
@screenFrame.y + @height + offset >= targetLayer.screenFrame.y && | |
@screenFrame.y - offset <= targetLayer.screenFrame.y + targetLayer.height | |
true | |
else | |
false | |
Layer::isInside = (targetLayer, offset = 0) -> |
// Simulate a call to Dropbox or other service that can | |
// return an image as an ArrayBuffer. | |
var xhr = new XMLHttpRequest(); | |
// Use JSFiddle logo as a sample image to avoid complicating | |
// this example with cross-domain issues. | |
xhr.open( "GET", "http://fiddle.jshell.net/img/logo.png", true ); | |
// Ask for the result as an ArrayBuffer. | |
xhr.responseType = "arraybuffer"; |