- I or iter or foreach: for each
- psf: public static final
- sout: sys.out()
- serr: sys.err()
- psvm: main()
- mx: max()
- mn: min()
- lazy: init var
- inst: instanceof
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
find . -name "file.txt" -exec grep -n phrase "{$1}" /dev/null \; | |
// other | |
grep -or ‘something\|someelse’ —include \*.kt . | sort -u |
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/sh | |
mogrify -path . -quality 80% -resize 33% $1 |
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/sh | |
convert $1 -strip $1_copy |
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/sh | |
function merge_2_images() { | |
convert +append -border 1 -bordercolor "#d3d3d3" $1 $2 merged.png | |
} | |
montage -geometry 100% -border 1 $1 $2 merged.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
#!/bin/sh | |
mogrify -path jpg -format jpg *.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
adb install -r <path> | |
adb shell pm clear <package> | |
adb shell input text <text> | |
adb shell am start -n <package/activity> | |
adb -d shell pm list packages -f <name> | |
adb pull <path> | |
adb shell dd if=/dev/zero of=/sdcard/myfile.dat bs=1024k count=1 |
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
1) use deep clean script https://github.com/rock3r/deep-clean | |
OR | |
1) close android studio | |
2) rm -rf ~/.gradle/caches/build-cache-1 | |
3) ./gradlew cleanBuildCache (clears android gradle plugin cache) | |
4) find . -type d -name "build" -exec rm -rf "{$1}" \; | |
5) clean build the app |
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
// reveal apk file in folder after release generated | |
applicationVariants.all { variant -> | |
variant.assemble.doLast { | |
//If this is a 'release' build, reveal the compiled apk in finder/explorer | |
if (variant.buildType.name.contains('release')) { | |
def path = null; | |
variant.outputs.each { output -> | |
path = output.outputFile | |
} |
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
[user] | |
email = [email protected] | |
name = User Name | |
[alias] | |
st = status | |
hist = log --pretty=format:\"%h %ad | %s%d [%an]\" --graph --date=short | |
unwatch = update-index --assume-unchanged | |
watch = update-index --no-assume-unchanged |