diff options
author | Silvio Rhatto <rhatto@riseup.net> | 2013-01-13 15:49:12 -0200 |
---|---|---|
committer | Silvio Rhatto <rhatto@riseup.net> | 2013-01-13 15:49:12 -0200 |
commit | a86446df9ba5ffb86d99c511217d704736803f3f (patch) | |
tree | 165a4ebbe08c3d1519f13696ab659e8af4814939 /modules/profile | |
download | dotfiles-a86446df9ba5ffb86d99c511217d704736803f3f.tar.gz dotfiles-a86446df9ba5ffb86d99c511217d704736803f3f.tar.bz2 |
Initial import
Diffstat (limited to 'modules/profile')
-rw-r--r-- | modules/profile/bashrc | 1 | ||||
-rw-r--r-- | modules/profile/geometry | 11 | ||||
-rw-r--r-- | modules/profile/profile | 33 | ||||
-rw-r--r-- | modules/profile/terminal | 38 | ||||
-rw-r--r-- | modules/profile/xinitrc | 12 | ||||
-rwxr-xr-x | modules/profile/xprofile | 40 | ||||
l--------- | modules/profile/xsession | 1 |
7 files changed, 136 insertions, 0 deletions
diff --git a/modules/profile/bashrc b/modules/profile/bashrc new file mode 100644 index 0000000..70bd631 --- /dev/null +++ b/modules/profile/bashrc @@ -0,0 +1 @@ +source $HOME/.profile diff --git a/modules/profile/geometry b/modules/profile/geometry new file mode 100644 index 0000000..7657e8d --- /dev/null +++ b/modules/profile/geometry @@ -0,0 +1,11 @@ +# +# Terminal geometry file configuration. +# + +TERM="rxvt" +FONT="-*-terminus-*-*-*-*-18-*-*-*-*-*-*-*" + +# Load custom configuration +if [ -e "$HOME/.custom/geometry" ]; then + source $HOME/.custom/geometry +fi diff --git a/modules/profile/profile b/modules/profile/profile new file mode 100644 index 0000000..8815deb --- /dev/null +++ b/modules/profile/profile @@ -0,0 +1,33 @@ +# +# .profile: basic environment setup +# + +# Set language +export LANG=pt_BR.UTF-8 + +# Source functions and variables from other places +if [ -e "$HOME/.aliases" ]; then + source $HOME/.aliases +fi + +# Funcoes ZZ +if [ -e "/usr/bin/funcoeszz" ]; then + source /usr/bin/funcoeszz +fi + +# Set PATH +export PATH=$PATH:/sbin:/usr/sbin:/usr/local/sbin:$HOME/apps/scripts + +# Editor variables, avoiding "Avoiding protocol specified" error +export EDITOR="vim -X" + +# SSH Agent +source $HOME/apps/scripts/ssh-agent-eval + +# GPG Agent +source $HOME/apps/scripts/gpg-agent-eval + +# Custom configuration +if [ -e "$HOME/.custom/profile" ]; then + source $HOME/.custom/profile +fi diff --git a/modules/profile/terminal b/modules/profile/terminal new file mode 100644 index 0000000..e496cbe --- /dev/null +++ b/modules/profile/terminal @@ -0,0 +1,38 @@ +#!/bin/bash +# +# .terminal: sets default behaviour for a X11 console +# + +# Load ANSI Art +#cat $HOME/themes/ans/slack.ans + +# Make sure to load the profile +source $HOME/.profile + +# Default window title +TITLE="terminal" + +# export PS1="\[\033[1;32m\]\332\304\[\033[0;32m\]\304(\[\033[0;32m\]\$(w | head -n 1) \[\033[0;32m\])\304\304( \[\033[0;36m\]\u\[\033[1;36m\]@\[\033[0;36m\]\h\[\033[0;32m\] )\304\304( \[\033[0;33m\]\w\[\033[0;32m\] )\n\[\033[1;32m\]\300\304\[\033[0;32m\]\304( \[\033[1;32m\]\\$\[\033[0;32m\] >\[\033[00m\] " + +# export PS1="\[\033[1;33m\]\332\304\[\033[0;33m\]\304(\[\033[0;32m\]\$(w | head -n 1) \[\033[0;33m\])\304\304( \[\033[0;36m\]\u\[\033[1;36m\]@\[\033[0;36m\]\h\[\033[0;33m\] )\304\304( \[\033[0;32m\]\w\[\033[0;33m\] )\n\[\033[1;33m\]\300\304\[\033[0;33m\]\304( \[\033[1;33m\]\\$\[\033[0;33m\] >\[\033[00m\] " + +# export PS1="\[\033[1;33m\]\332\304\[\033[0;33m\]\304(\[\033[0;33m\]\$(w | head -n 1) \[\033[0;33m\])\304\304( \[\033[0;36m\]\u\[\033[1;36m\]@\[\033[0;36m\]\h\[\033[0;33m\] )\304\304( \[\033[0;32m\]\w\[\033[0;33m\] )\n\[\033[1;33m\]\300\304\[\033[0;33m\]\304( \[\033[1;33m\]\\$\[\033[0;33m\] >\[\033[00m\] " + +#export PS1="\[\033[1;33m\]\332\304\[\033[0;33m\]\304(\[\033[0;33m\] $( date +%H:%M:%S ) \[\033[0;33m\])\304\304( \[\033[0;36m\]\u\[\033[1;36m\]@\[\033[0;36m\]\h\[\033[0;33m\] )\304\304( \[\033[0;32m\]\w\[\033[0;33m\] )\n\[\033[1;33m\]\300\304\[\033[0;33m\]\304( \[\033[1;33m\]\\$\[\033[0;33m\] >\[\033[00m\] " + +# Set window title, standard version +#trap 'echo -ne "\e]0;terminal: ${TITLE:-$BASH_COMMAND}\007"' DEBUG +#trap 'xtitle ${TITLE:-$BASH_COMMAND}' DEBUG + +# Set window title, special version +# +# In the standard version, $_ stops to keep the parameter of the last command. +# The sollution is to save the value of $_ and issue a pointless command with +# it after changing the title so $_ retain it's intended value. +# +#trap 'last="$_" ; echo -ne "\e]0;terminal: ${TITLE:-$BASH_COMMAND}\007"; true $last' DEBUG +#trap 'last="$_" ; xtitle ${TITLE:-$BASH_COMMAND}; true $last' DEBUG +trap '_last="$_" ; _command=${BASH_COMMAND#command_prompt} ; xtitle ${_command:-$TITLE}; true $_last' DEBUG + +# Fortune :) +#fortune diff --git a/modules/profile/xinitrc b/modules/profile/xinitrc new file mode 100644 index 0000000..fdd35b1 --- /dev/null +++ b/modules/profile/xinitrc @@ -0,0 +1,12 @@ +#!/bin/bash +# +# .xinitrc: set basic X11 environment for non-X11 runlevel +# + +# Load .xprofile +source $HOME/.xprofile & + +# Run window manager +#enlightenment +#fluxbox +awesome diff --git a/modules/profile/xprofile b/modules/profile/xprofile new file mode 100755 index 0000000..bfafe46 --- /dev/null +++ b/modules/profile/xprofile @@ -0,0 +1,40 @@ +#!/bin/bash +# +# .xprofile: set basic X11 environment +# + +# Background image +BACKGROUND="" + +# Session applications +PROGRAMS="" + +# Make sure to load the profile +source $HOME/.profile + +# Start xscreensaver +xscreensaver -no-splash & + +# Custom +if [ -e "$HOME/.custom/xprofile" ]; then + source $HOME/.custom/xprofile +fi + +# Set background +if [ ! -z "$BACKGROUND" ]; then + Esetroot -scale $HOME/.config/themes/backgrounds/$BACKGROUND +else + xsetroot -solid black +fi + +# Additional applications depending on the machine type +if laptop-detect; then + PROGRAMS="$PROGRAMS wicd-client" +else + PROGRAMS="$PROGRAMS" +fi + +# Start session applications +for program in $PROGRAMS; do + $program & +done diff --git a/modules/profile/xsession b/modules/profile/xsession new file mode 120000 index 0000000..68a5612 --- /dev/null +++ b/modules/profile/xsession @@ -0,0 +1 @@ +xprofile
\ No newline at end of file |