소스 검색

Updated host-specific shell-file edit script

Samuel W. Flint 8 년 전
부모
커밋
ab3620f31c
1개의 변경된 파일6개의 추가작업 그리고 4개의 파일을 삭제
  1. 6 4
      edit-host-specific-shell-file

+ 6 - 4
edit-host-specific-shell-file

@@ -3,9 +3,11 @@
 if [[ -f ~/.`hostname`.zsh ]] ; then
     eaf ~/.`hostname`.zsh
 else
-    echo "# -*- shell-script -*-" > ~/.`hostname`.zsh
-    echo "# $(hostname) specific config" >> ~/.`hostname`.zsh
-    echo "" >> ~/.`hostname`.zsh
-    echo "" >> ~/.`hostname`.zsh
+    cat <<EOF > ~/.`hostname`.zsh
+# -*- shell-script -*-
+# $(hostname) specific configuration
+
+echo "You are on $(hostname -s)
+EOF
     eaf ~/.`hostname`.zsh
 fi