Skip to content

Instantly share code, notes, and snippets.

@fraserr
fraserr / fblogin-handler.js
Created October 2, 2018 23:14 — forked from kimerran/fblogin-handler.js
facebook login test
var FbApp = {
init: {
appId: '144919695582243',
cookie: true,
xfbml: true,
version: 'v2.1'
},
// called when user is currently logged-in and already authorized the app
onConnected: function() {
$("#fblogin").hide();
@fraserr
fraserr / gist:5243df329f81b7e45758a48562d4b266
Created September 12, 2017 15:00
docker run elasticsearch without x pack
docker run -d -p 9200:9200 --name elasticsearch -e "http.host=0.0.0.0" -e "transport.host=127.0.0.1" -e "xpack.security.enabled=false" docker.elastic.co/elasticsearch/elasticsearch:5.2.
@fraserr
fraserr / commit-msg.sh
Created May 26, 2017 13:50 — forked from veewee/commit-msg.sh
Enforce the JIRA issue number in a GIT commit message
#!/bin/sh
# This hook will make sure that the commit message contains a JIRA issue.
#
# To enable this hook, rename this file to ".git/hooks/commit-msg".
# Make sure to add execution permissions to the file.
export MESSAGE=$(<$1)
export JIRA_ISSUE_TAG='ISSUETAG-([0-9]*)'
if [[ $MESSAGE =~ $JIRA_ISSUE_TAG ]]; then
@fraserr
fraserr / 0_reuse_code.js
Created May 19, 2016 15:57
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console