This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Place this in the 'build.gradle' of the library module | |
// Task : Generate a JAR | |
// Usage : In the terminal, run './gradlew jar' | |
// Output : Get the jar at 'build/libs' | |
task jar(type: Jar, dependsOn: 'assembleRelease') { | |
from fileTree(dir: 'build/intermediates/classes/release') | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
PATH=/usr/local/bin:/usr/bin:/bin | |
# cd to the directory of the image so we can work with just filenames | |
dir="$(dirname "$1")" | |
cd "$dir" || exit 1 | |
base="$(basename "$1" .png)" | |
# create a WebP version of the PNG |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This is a test shell script | |
echo "Hello World" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// Regular Expression for URL validation | |
// | |
// Author: Diego Perini | |
// Updated: 2010/12/05 | |
// License: MIT | |
// | |
// Copyright (c) 2010-2013 Diego Perini (http://www.iport.it) | |
// | |
// Permission is hereby granted, free of charge, to any person |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### Create Maven Repository | |
#Create a directory named mavenrepo | |
mkdir mavenrepo | |
#Move into the dir | |
cd mavenrepo | |
#Initialise with git | |
git init |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Start battery historian | |
cd $GOPATH/src/github.com/google/battery-historian | |
go run cmd/battery-historian/battery-historian.go | |
#Setup device for data collection | |
./adb shell dumpsys batterystats --enable full-wake-history | |
./adb shell dumpsys batterystats --reset | |
#Capture bugreport | |
./adb bugreport > ./bugreports/android_device_bugreport.txt |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#For more info check : http://people.duke.edu/~hpgavin/gnuplot.html | |
#Install GnuPLot | |
brew install gnuplot | |
#Before ploting a graph, set the terminal into dumb mode | |
set terminal dumb | |
#To Plot a graph | |
plot cos(x+2) #for a function | |
#for a data set |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.ellipsis { | |
white-space: nowrap; | |
overflow: hidden; | |
text-overflow: ellipsis; // IE 6+, FF 7+, Op 11+, Saf 1.3+, Chr 1+ | |
-o-text-overflow: ellipsis; // for Opera 9 & 10 | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
buildTypes { | |
debug { | |
minifyEnabled false | |
applicationIdSuffix '.debug' | |
versionNameSuffix '-debug' | |
} | |
release { | |
signingConfig signingConfigs.release | |
minifyEnabled true | |
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#More info at : https://help.github.com/articles/generating-ssh-keys/ | |
cat ~/.ssh/id_dsa.pub |