Permalink
Browse files

wip: port c2prompt from perl to ruby

  • Loading branch information...
1 parent 415ac9b commit b1179ef29ab88824bb71f9c7243ae2fa5f984c46 dirk luesebrink committed Apr 13, 2011
Showing with 3 additions and 3 deletions.
  1. +1 −1 packages/pathfix.sh
  2. +1 −2 packages/prompt.sh
  3. +1 −0 rc-packages.sh
View
@@ -1,5 +1,5 @@
function pathfix {
- script=${RC_PACKAGES}/../scripts/pathfix.rb
+ script=${RC_SCRIPT_DIR}/pathfix.rb
new_path=$(${script} $*)
if [ "$?" == 0 ]; then
PATH=${new_path}
View
@@ -29,12 +29,11 @@ function cd() {
builtin cd "${1:-${HOME}}"
#echo --$1--
- w=$(~/rc/c2prompt.pl)
+ w=$(${RC_SCRIPT_DIR}/c2prompt.rb)
#echo --$w--
#PS1="\e[39m\u\e[m \e[32m\h\e[0m\] ${w}: "
#PS1="\[\e[1;31;44m\] \u \[\e[0m\] @ \[\e[32m\h\[\e[0m\] ${w}: "
PS1="\[\033[39m\]\u \[\033[32m\]\h \[\033[39m\]${w}: "
#PS1="\[\e[39m\]\u\[\e[0m\]@\[\e[32m\h\[\e[0m\] ${w}: "
PS2=" >> "
}
-
View
@@ -10,6 +10,7 @@ fi
# define base dir for packages and further source commands
RC_PACKAGES_DIR=$(dirname ${BASH_SOURCE})/packages
+RC_SCRIPT_DIR=$(dirname ${BASH_SOURCE})/scripts
# debug echo function
function decho() {

0 comments on commit b1179ef

Please sign in to comment.