Skip to content

Instantly share code, notes, and snippets.

View hacfi's full-sized avatar

hacfi hacfi

  • Certified Symfony developer
  • Europe
View GitHub Profile
@nikicat
nikicat / travis.sh
Last active January 6, 2016 10:34
Shell build script to handle .travis.yml inside Jenkins
#!/bin/bash -exv
function getvalue() {
shyaml get-value $1 < .travis.yml
}
function getencvalue() {
shyaml get-value $1.secure < .travis.yml | base64 -d | openssl rsautl -decrypt -inkey .jenkins.pem
}
@BinaryMuse
BinaryMuse / README.md
Last active February 1, 2017 00:51
Integrating React with Marionette

Integrating React with Marionette

See ReactComponentView and BackboneModelWatchMixin, below.

Notes

The BackboneModelWatchView could use some additional methods to allow adding/removing watched models after the component is created.

@oroce
oroce / README.md
Created June 12, 2014 07:51
nginx request id
#!/bin/bash
#
# The MIT License (MIT)
#
# Copyright (c) 2014 Mathias Leppich <[email protected]>
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
# Reveal Library
chflags nohidden ~/Library
# Install homebrew
ruby -e "$(curl -fsSL https://raw.github.com/Homebrew/homebrew/go/install)"
# Install homebrew cask
brew install caskroom/cask/brew-cask
# Install all necessary sw
brew cask install google-chrome
brew cask install firefox
brew cask install spectacle
#!/usr/bin/env zsh
branch=`git rev-parse --abbrev-ref HEAD`
git show-branch | ack '\*' | ack -v "$branch" | head -n1 | sed 's/.*\[\(.*\)\].*/\1/' | sed 's/[\^~].*//'
# How it works:
# 1| Display a textual history of all commits.
# 2| Ancestors of the current commit are indicated
# by a star. Filter out everything else.
@philfreo
philfreo / hijack-links.js
Created February 26, 2014 22:41
Hijack in-site links for Backbone.js
@tim-peterson
tim-peterson / UploadHandlerS3.php
Last active October 18, 2024 11:39
jQuery-File-Upload S3 PHP upload directly using AWS PHP SDK V2 (w/ optional Dropbox Chooser-selected files) https://github.com/blueimp/jQuery-File-Upload
<?php
use Aws\Common\Aws;
use Aws\S3\Exception\S3Exception;
// make sure the SDK is installed
// I've used Composer to autoload it: http://docs.aws.amazon.com/aws-sdk-php/guide/latest/installation.html
/*
* jQuery File Upload Plugin PHP Class 7.1.0
* https://github.com/blueimp/jQuery-File-Upload
@phpfour
phpfour / Vagrantfile
Created December 5, 2013 11:15
ElasticSearch in Vagrant
Vagrant.configure("2") do |config|
config.vm.box = "precise64"
config.vm.box_url = "http://files.vagrantup.com/precise64.box"
config.vm.network :private_network, ip: "192.168.56.115"
config.vm.network :forwarded_port, guest: 80, host: 81 #for Kibana3
config.vm.network :forwarded_port, guest: 5601, host: 5601 #for Kibana2, if you prefer
config.vm.network :forwarded_port, guest: 9200, host: 9201 #for ElasticSearch Master