Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve guide #2

Open
ghost opened this issue Aug 22, 2015 · 3 comments
Open

Improve guide #2

ghost opened this issue Aug 22, 2015 · 3 comments

Comments

@ghost
Copy link

ghost commented Aug 22, 2015

Replace Display Manager recommendations with:

Set the $HOME dir for zsh and xinitrc in .zshenv

ZDOTDIR="${ZDOTDIR:-$HOME/.config/zsh}"
export XINITRC="$HOME/.config/xinitrc"

.zlogin

if [[ -z "$DISPLAY" ]] && [[ $(tty) == /dev/tty1 ]]
then
    xauth -qf "$HOME/.cache/.Xauthority" add ':0' . `mcookie`
    exec xinit xmonad -- :0 -auth "$HOME/.cache/.Xauthority" -nolisten tcp vt1
fi

At the bottom (very end) of xinitrc

...

session=${1:-dwm}

case $session in
    openbox)
        exec openbox-session
        ;;

    dwm)
        exec dwm
        ;;

    xmonad)
        exec xmonad
        ;;

    *)
        printf '%s\n' 'System failure, abandon the ship.'
        ;;
esac

Recommend the use of elevator=noop a.k.a "noop" scheduler

Replace the gui archive extraction and creation programs with shell one (when in extraction, the archive have to read by the gui program in order to show x% completed extraction dialogue), and do the extraction in TMPFS. Don't install two additional programs to extract and create zip archives, python is here to do the job.

Archive extraction functions.

Archive creation functions, some of the compression programs (gzip - pigz, bzip2 - lbzip2) support parallel compression to speed the things up.

Wrap up the archive extraction and creation functions to be used by your file manager as plugin.

Replace the gui network managers with shell one as functions to make use of random internal ip and random MAC addresses.

Point links to my openbox including theme, dwm including dwm-bar.c statusbar, xmonad configuration files as examples/source.

Add the modprobed-db by @graysky2.

Optimizing mkinitcpio.conf guide by falconindy - http://blog.falconindy.com/articles/optmizing-bootup-with-mkinitcpio.html , warn the people using LUKS not to use it.

Recommend the usage of urxvt that is lightweight on resources terminal and extensible via plugins.

Add the following at the top of xinitrc in order to utilize the urxvt daemon, instead starting standalone instances of the terminal. The urxvt client is started with urxvtc command.

urxvtd --quiet --opendisplay --fork &
@ranisalt
Copy link
Owner

Thanks! I'm working on those suggestions, but clarify for me: why the first part about zsh configuration? I don't understand the purpose, I want this guide to be system-agnostic, preferably not even depending on shell (I personally don't use a bash-compatible shell)

@ranisalt
Copy link
Owner

Recommend the use of elevator=noop a.k.a "noop" scheduler

Done

Optimizing mkinitcpio.conf guide by falconindy - http://blog.falconindy.com/articles/optmizing-bootup-with-mkinitcpio.html , warn the people using LUKS not to use it.

Done

@ghost
Copy link
Author

ghost commented Sep 1, 2015

Hello Ranieri,

why the first part about zsh configuration

ZDOTDIR:

If ZDOTDIR is unset, HOME is used instead. Commands are then read from $ZDOTDIR/.zshenv. If the shell is a login shell, commands are read from /etc/zprofile and then $ZDOTDIR/.zprofile.
Then, if the shell is interactive, commands are read from /etc/zshrc and then $ZDOTDIR/.zshrc. Finally, if the shell is a login shell, /etc/zlogin and $ZDOTDIR/.zlogin are read.
When a login shell exits, the files $ZDOTDIR/.zlogout and then /etc/zlogout are read. This happens with either an explicit exit via the exit or logout commands, or an implicit exit by reading end-of-file from the terminal.
However, if the shell terminates due to exec'ing another process, the logout files are not read.

The part is there to set the environment variable XINITRC which points the locations of the file called xinitrc.

There are .config and .local directories where not user related configuration files, scripts and so forth should go.

I personally don't use a bash-compatible shell

The presented code is posix-compliant.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant