cm13 gcc6 urushi

i have this old sony xperia st18i(urushi) iam using as a music player, and build roms for it every once in a while.
i tought id share my build and how to flash it from ubuntu :

first download the rom here : DOWNLOAD

than install adb and fastboot from the repo :

 sudo apt-get install android-tools-adb android-tools-fastboot android-tools-adbd 

than open the rom file and extract the boot.img

now on your phone enable developer mode, by tapping the build number 8 times
enable usb debuging

back on the computer again run the following from within the directory where you extracted boot.img:

 sudo adb reboot-bootloader
sudo fastboot flash boot boot.img
sudo fastboot reboot 

when the phone is rebooting you will see the home button flash press the volume keys at that moment to boot in to recovery
when in recovery do a factory reset when needed, and select apply update and apply from ADB

than on the computer run :

sudo adb sideload romname.zip
# in this example its : 
sudo adb sideload cm-13.0-20160710-UNOFFICIAL-LegacyXperia-urushi

wait , reboot and you are done,
you can flash open gapps if wanted : Gapps

How to enable arpon ( prevent arp spoofing)

To prevent arp poisoning in ubuntu.
you will have to install arpon
to install arpon run :

sudo apt-get install arpon

than you have to enable arpon by default by editing /etc/default/arpon
make it look like :

# Defaults for arpon initscript
# sourced by /etc/init.d/arpon
# installed at /etc/default/arpon by the maintainer scripts


# You must choose between static ARP inspection (SARPI) and
# dynamic ARP inspection (DARPI)
#
# For SARPI uncomment the following line (please edit also /etc/arpon.sarpi)
# DAEMON_OPTS="-q -f /var/log/arpon/arpon.log -g -s"

# For DARPI uncomment the following line
DAEMON_OPTS="-q -f /var/log/arpon/arpon.log -g -D"

# Modify to RUN="yes" when you are ready
RUN="yes"

than run :

sudo service arpon restart

(be careful in the default Ubuntu install the D is not capital and prevents arpon from starting)
and your done !

zsh in ubuntu

Zsh is a shell designed for interactive use, although it is also a powerful scripting language, in this post i will describe how to install and configure it

first install it from the repository by doing :

 sudo apt-get install zsh 

to install the grml config issu the following command in your home dir :

 wget -O .zshrc http://git.grml.org/f/grml-etc-core/etc/zsh/zshrc 

to also install the user config from grml issue :

 wget -O .zshrc.local  http://git.grml.org/f/grml-etc-core/etc/skel/.zshrc 

to enable fish like syntax highlighting :

 git clone https://github.com/zsh-users/zsh-syntax-highlighting.git
    echo "source ${(q-)PWD}/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh" >> ${ZDOTDIR:-$HOME}/.zshrc

Then, enable syntax highlighting in the current interactive shell:

 source ./zsh-syntax-highlighting/zsh-syntax-highlighting.zsh 

to test your newly installed zsh shell run zsh in bash
if you want to use zsh as your default shell issue :

 chsh -s $(which zsh) 

Xubuntu awsome install

awesome is a tiling window manager for linux

Installing awesome is as easy as doing :

sudo apt-get install -y awesome awesome-extra

by default awesome has no network manager or compositing to fix this we are going to use unagi and nm-applet

for compositing install :

sudo apt-get install -y unagi

and add the following to your /home/$username/.config/awesome/rc.lua:

awful.util.spawn_with_shell("unagi &")

to add a network manager just add the following to your /home/$username/.config/awesome/rc.lua

awful.util.spawn_with_shell("nm-applet &")