Skip to content

Instantly share code, notes, and snippets.

View mugli's full-sized avatar
🤷

Mehdi Hasan Khan mugli

🤷
View GitHub Profile
@mugli
mugli / init.d play
Created November 19, 2013 11:30 — forked from bihe/init.d play
#!/bin/sh
### BEGIN INIT INFO
## END INIT INFO
# Path to play install folder
PLAY_HOME=/usr/share/play
PLAY=$PLAY_HOME/play
# Path to the JVM
JAVA_HOME=/usr/lib/jvm/java-1.6.0-openjdk
@mugli
mugli / README.md
Last active January 5, 2016 23:33
Using stud (The Scalable TLS Unwrapping Daemon) on Ubuntu 12.04

Using stud (The Scalable TLS Unwrapping Daemon) on Ubuntu 12.04

stud repo: https://github.com/bumptech/stud

###Compiling from source: stud on Ubuntu repository is outdated. Here's how to compile that from source:

  sudo apt-get install -y libev-dev libssl-dev git-core
  
  git clone git://github.com/bumptech/stud.git
@mugli
mugli / install-java7.sh
Created January 30, 2014 21:51
Silently install Oracle Java 7 on Ubuntu (without license agreement step)
#!/bin/bash
sudo apt-get install -y python-software-properties
sudo add-apt-repository -y ppa:webupd8team/java
sudo apt-get update
# Enable silent install
echo debconf shared/accepted-oracle-license-v1-1 select true | sudo debconf-set-selections
echo debconf shared/accepted-oracle-license-v1-1 seen true | sudo debconf-set-selections
@mugli
mugli / titan.conf
Last active December 30, 2015 05:11
Titan server upstart script for Ubuntu 12.04
### Titan upstart script (with Rexster and Elasticsearch & Cassandra embedded mode)
### Change rexster_config & titan_config values for different configurations
### Works with Titan Server version "0.4.x"
### This file goes to /etc/init/titan.conf
description "Titan - Distributed Graph Database"
start on (runlevel [2345] and local-filesystems and net-device-up IFACE!=lo)
stop on runlevel [!2345]
'use strict';
var gulp = require('gulp');
var uglify = require('gulp-uglify');
var imagemin = require('gulp-imagemin');
var Server = require('.');
gulp.task('scripts', function () {
return gulp.src(['client/js/**/*.js', '!client/js/vendor/**'])
.pipe(uglify())
@mugli
mugli / gulpfile.js
Created February 17, 2014 17:52 — forked from yocontra/gulpfile.js
var gulp = require('gulp');
var gutil = require('gulp-util');
var express = require('express');
var path = require('path');
var tinylr = require('tiny-lr');
var createServers = function(port, lrport) {
var lr = tinylr();
lr.listen(lrport, function() {
gutil.log('LR Listening on', lrport);
var gulp = require('gulp');
var gutil = require('gulp-util');
var sass = require('gulp-sass');
var lr = require('tiny-lr');
var http = require('http');
var path = require('path');
var ecstatic = require('ecstatic');
var tlr = lr();
var livereload = function (evt, filepath) {
tlr.changed({
var gulp = require('gulp');
// Let's make things more readable by
// encapsulating each part's setup
// in its own method
function startExpress() {
var express = require('express');
var app = express();
app.use(express.static(__dirname));
#!/usr/bin/ruby
# Create display override file to force Mac OS X to use RGB mode for Display
# see http://embdev.net/topic/284710
require 'base64'
data=`ioreg -l -d0 -w 0 -r -c AppleDisplay`
edids=data.scan(/IODisplayEDID.*?<([a-z0-9]+)>/i).flatten
vendorids=data.scan(/DisplayVendorID.*?([0-9]+)/i).flatten
/ - Quick Add
Hold Shift while resizing - Maintain aspect ration
Hold Command while moving object - Removes snapping
Shift + Direction while an object is selected - Moves object faster
Command + Alt + (Shift) + Direction while an object is selected - Resizes object
Command + Up/Down - Moves selected layer up or down 1 level
Command + (Shift) + Up/Down - Moves selected layer to top or bottom layer
Alt + Drag object - Duplicate object
Shift + click another object - Add object to current selection
Command + click another object - Add object to current selection