Home

Awesome

Gentoo Linux plugin

This plugin adds some aliases and functions to work with Gentoo Linux.

Features

EMERGE

AliasCommandDescription
eminsudo emerge <atom>Install the <atom> packet in the system
eminslsudo emerge -K <atom>Install the <atom> packet using a local binary
eminsrsudo emerge -G <atom>Install the <atom> packet using a remote binary
emresudo emerge -C <atom>Uninstall the <atom> packet in the system
emsearchemerge -s <atom>Search the <atom> packet in the local repository
emsyncsudo emerge --syncSync the local repository with the remote repository
emupsudo emerge -aDuN worldUpdate the packages in the local system
emcleansudo emerge --depcleanDelete the unwanted software

EIX

AliasCommandDescription
eisyncsudo eix-syncUpdate the local eix cache
eirupsudo eix-remote updateUpdate the remotes by saving locally layman caches
eiroveix -R <overlay>Search all overlay

PORTAGEQ

AliasCommandDescription
pocolorportageq colormap Display the color.map as environment variables
podistportageq distdir Returns the DISTDIR path
povarportageq envvar Returns a specific environment variable as exists prior to ebuild.sh
pomirrorportageq gentoo_mirrorsReturns the mirrors set to use in the portage configuration
poorphanportageq --orphaned Match only orphaned (maintainer-needed) packages

GENLOP

AliasCommandDescription
genstorysudo genlop -lShow full merge history
genetasudo genlop -cDisplay the currently compiling packages (if any)
genwetawatch -ct -n 1 sudo genlop -cDisplay the currently compiling packages (if any), with refresh
geninfosudo genlop -i <atom>Extra infos for the selected <atom> (build specific USE, CFLAGS)
genustorysudo genlop -uShow when packages have been unmerged
genstorytimesudo genlop -t <atom>Calculate merge time for the specific <atom(s)>

QLOP

AliasCommandDescription
qsummarysudo qlop -cPrint summary of average merges
qtimesudo qlop -tPrint time taken to complete action
qavgsudo qlop -aPrint average time taken to complete action
qhumsudo qlop -HPrint elapsed time in human readable format
qmachinesudo qlop -MPrint start/elapsed time as seconds with no formatting
qmstorysudo qlop -mShow merge history
qustorysudo qlop -uShow unmerge history
qastorysudo qlop -UShow autoclean unmerge history
qsstorysudo qlop -sShow sync histroy
qendsudo qlop -eReport time at which the operation finished (iso started)
qrunsudo qlop -rShow current emerging packages

ECLEAN

AliasCommandDescription
distcleansudo eclean --deep distfilesClean files from /usr/portage/distfiles
pkgcleansudo eclean-pkgClean files from /usr/portage/packages

EUSE

AliasCommandDescription
newusesudo euse -E <use>Add th <use> flag in /etc/portage/make.conf
delusesudo euse -D <use>Delete th <use> flag in /etc/portage/make.conf

VIM

AliasCommandDescription
make.confsudo vim /etc/portage/make.confOpen the make.conf configuration file
package.masksudo vim /etc/portage/package.maskOpen the package.mask configuration file
package.usesudo vim /etc/portage/package.useOpen the package.use configuration file
repos.confsudo vim /etc/portage/repos.confOpen the repos.conf configuration file
eix-sync.confsudo vim /etc/eix-sync.confOpen the /etc/eix-sync.conf configuration file
eixrcsudo vim /etc/eixrcOpen the /etc/eixrc configuration file

Installation

You need to install the ohmyzsh framework with:

sh -c "$(wget -O- https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"

Next, you have to clone this plugin in ~/.oh-my-zsh/custom/plugins/gentoolinux:

git clone https://github.com/MattiaG-afk/gentoolinux-ohmyzsh.git ${ZSG_CUSTOM:-~/.oh-my-zsh/custom}/plugins/gentoolinux

Finally, open .zshrc and enable the plugins by adding 'gentoo' in 'plugins=(...)':

plugins=(... gentoolinux)

If you don't have gentoolkit installed you will need to install it with the command:

sudo emerge genlop

If you don't have eix installed you will need to install it with the command:

sudo emerge eix

Now restart your terminal, or run:

source ~/.zshrc