Skip to content

Instantly share code, notes, and snippets.

View elmodos's full-sized avatar
🇺🇦

Modo Ltunzher elmodos

🇺🇦
View GitHub Profile
@elmodos
elmodos / .bashrc
Created October 21, 2016 14:29
256 color terminal for GUI terminal emulator
# paster this into the end of your ~/.bashrc file
# 256 color by default for X
if [ -n "$DISPLAY" -a "$TERM" == "xterm" ]; then
export TERM=xterm-256color
fi
@elmodos
elmodos / espeak.sh
Created May 1, 2016 18:04
Linux, say current selection aloud, espeak
#!/bin/bash
# Get espeak PID if it is running
PID=`pgrep -x espeak`
echo Process ID: $PID
if [ -z $PID ];
then
# Not runnning
@elmodos
elmodos / revision.sh
Last active March 31, 2016 13:27
Add this script to Build Phases of your target in Xcode to automatically set build number with SVN/Git revision number
# set build number only for release (Product|Archive)
if [ "$CONFIGURATION" == "Release" ]; then
# get GIT revision number
buildNumber=`git rev-list --count HEAD`
# if not git, then get SVN revision number
if [[ -z "$buildNumber" ]]; then
buildNumber=`svn info | grep "Revision" | awk '{print $2}'`
fi