基本的な問題: ターミナルで新しいタブを開くと、bash が次のエラー出力で失敗します。
bash: -c: line 0: syntax error near unexpected token `('
bash: -c: line 0: `exec -la (null) (null) -1'
[Process completed]
環境設定で、同じ設定/ディレクトリで開くように設定された新しいタブがあります。
実際にこの問題を解決しようとして、bashプロンプト領域をカスタマイズすることを学びましたが、役に立ちませんでした。/etc/bashrc をいじってから、ユーザーがそれを行う必要があることに気付く前に、そのファイルを次のようにリセットしました。
# System-wide .bashrc file for interactive bash(1) shells.
if [ -z "$PS1" ]; then
return
fi
PS1='\h:\W \u\$ '
# Make bash check its window size after a process completes
shopt -s checkwinsize
# Tell the terminal about the working directory at each prompt.
if [ "$TERM_PROGRAM" == "Apple_Terminal" ] && [ -z "$INSIDE_EMACS" ]; then
update_terminal_cwd() {
# Identify the directory using a "file:" scheme URL,
# including the host name to disambiguate local vs.
# remote connections. Percent-escape spaces.
local SEARCH=' '
local REPLACE='%20'
local PWD_URL="file://$HOSTNAME${PWD//$SEARCH/$REPLACE}"
printf '\e]7;%s\a' "$PWD_URL"
}
PROMPT_COMMAND="update_terminal_cwd; $PROMPT_COMMAND"
fi
最後に、 ~/.bash_profile は次のようになります。
source /etc/bashrc
export PATH=~/Code:/usr/local/bin:/bin:/usr/bin:/sbin:/usr/sbin.
export CLASSPATH=~/Programs/:~/Programs/bailey.jar:~/Programs/labs/:.
export PYTHONPATH=~/dm/:~/Code/Git/.:.
誰かが私に何か提案をすることができれば、それは素晴らしいことです.