소스 검색

setup.sh: code improvements

rain.esteva 1 년 전
부모
커밋
6356735a42
1개의 변경된 파일7개의 추가작업 그리고 4개의 파일을 삭제
  1. 7 4
      setup.sh

+ 7 - 4
setup.sh

@@ -19,11 +19,11 @@ function add_string_to_file() {
 
 # Bashrc
 add_string_to_file "$HOME/.bashrc" "# Setup Aliases"
-add_string_to_file "$HOME/.bashrc" "source $HOME/dots/aliases" && source "$HOME/.bashrc"
-add_string_to_file "$HOME/.bashrc" "source $HOME/dots/seafly-prompt" && source "$HOME/.bashrc"
+add_string_to_file "$HOME/.bashrc" "source $HOME/dots/aliases"
+add_string_to_file "$HOME/.bashrc" "source $HOME/dots/seafly-prompt"
 
 add_string_to_file "$HOME/.bashrc" "# Scripts"
-add_string_to_file "$HOME/.bashrc" "bash $HOME/dots/life.sh 1993-07-21 control" && source "$HOME/.bashrc"
+add_string_to_file "$HOME/.bashrc" "bash $HOME/dots/life.sh 1993-07-21 control"
 
 # NVIM
 mkdir -p "$HOME/.config/nvim/"
@@ -37,5 +37,8 @@ cp "./tmux.conf" "$HOME/.tmux.conf"
 if [ -f "$HOME/.user_paths" ]; then
     chmod 660 "$HOME/.user_paths"
     add_string_to_file "$HOME/.bashrc" "# PATH FILE"
-    add_string_to_file "$HOME/.bashrc" "source $HOME/.user_paths" && source "$HOME/.bashrc"
+    add_string_to_file "$HOME/.bashrc" "source $HOME/.user_paths"
 fi
+
+# Source
+source "$HOME/.bashrc"