Skip to content

Instantly share code, notes, and snippets.

View frsela's full-sized avatar

Fernando Rodríguez Sela frsela

View GitHub Profile
@frsela
frsela / split.sh
Created January 18, 2013 11:28
[WIP] Splitting notification server repository
git clone ../notification_server/
cd notification_server
git filter-branch --prune-empty --index-filter 'git rm --cached --ignore-unmatch node_modules/* test/jmeter/* test/jMeter/*' HEAD
cd ..
git clone notification_server notification_server_base
rm -rf notification_server
git clone ../notification_server/
cd notification_server
git filter-branch --prune-empty --subdirectory-filter node_modules/
@frsela
frsela / PR.sh
Created August 1, 2013 08:04
Pull Request Link from bugzilla Creates a HTML file which links the PR as bugzilla patch
if [ -z $1 ]; then
echo "PR number needed !"
exit -1
fi
cat > /tmp/PR$1.html << EOF
<!DOCTYPE html>
<meta charset="utf-8">
<meta http-equiv="refresh" content="5;https://github.com/mozilla-b2g/gaia/pull/$1">
<title>Bugzilla Code Review</title>
@frsela
frsela / .bashrc
Created August 1, 2013 10:00
GIT Branch in PROMPT (old release)
...
# GIT
# Add git branch name to prompt
parse_git_branch() {
git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/(git::\1)/'
}
parse_svn_branch() {
parse_svn_url | sed -e 's#^'"$(parse_svn_repository_root)"'##g' | awk -F / '{print "(svn::"$1 "/" $2 ")"}'
@frsela
frsela / get.omni.ja.from.phone.sh
Last active August 29, 2015 14:07
Get OMNI.JA from the FFOS phone
if [ $# -eq 0 ]; then
echo "Indica carpeta dónde dejar el contenido del omni.ja"
exit
fi
adb pull /system/b2g/omni.ja .
mkdir $1
cd $1
unzip ../omni.ja
cd ..
@frsela
frsela / update.omni.ja.sh
Last active August 29, 2015 14:07
Update OMNI.JA to the FFOS phone
if [ $# -eq 0 ]; then
echo "Indica carpeta dónde está el contenido para el omni.ja"
exit
fi
cd $1
zip /tmp/omni.ja -r *
cd ..
adb shell stop b2g
adb remount
@frsela
frsela / enablePushTraces.sh
Last active August 29, 2015 14:14
Enable Push traces on a Firefox OS device
echo "Enabling PushService traces on your FFOS connected device..."
AUXPATH=_____PUSH_____
echo "Getting OMNI.JA..."
adb pull /system/b2g/omni.ja .
mkdir $AUXPATH
cd $AUXPATH
unzip ../omni.ja
rm ../omni.ja