Windows 10 窗口10上的git bash出现问题,最近的一次更改使我无法更新它
我已经安装了Git版本2.31.1.windows.1,并重新安装了它。我对其进行了更改以添加新别名。我做的一件事是,我试图获取文件源以重新加载它,但收到了此错误 bash:/c/Users/DawsonSchaffer/.bashrc:Bad address 所以我恢复了我以前的版本,运行良好。然而,我现在仍然得到相同的错误。我知道这不是很多这是我的.bashrc文件Windows 10 窗口10上的git bash出现问题,最近的一次更改使我无法更新它,windows-10,git-bash,Windows 10,Git Bash,我已经安装了Git版本2.31.1.windows.1,并重新安装了它。我对其进行了更改以添加新别名。我做的一件事是,我试图获取文件源以重新加载它,但收到了此错误 bash:/c/Users/DawsonSchaffer/.bashrc:Bad address 所以我恢复了我以前的版本,运行良好。然而,我现在仍然得到相同的错误。我知道这不是很多这是我的.bashrc文件 # History settings HISTCONTROL=ignoreboth shopt -s histappend H
# History settings
HISTCONTROL=ignoreboth
shopt -s histappend
HISTSIZE=1000
HISTFILESIZE=10000
HISTTIMEFORMAT="%F %T "
# uncomment for a colored prompt, if the terminal has the capability; turned
# off by default to not distract the user: the focus in a terminal window
# should be on the output of commands, not on the prompt
force_color_prompt=yes
if [ -n "$force_color_prompt" ]; then
if [ -x /usr/bin/tput ] && tput setaf 1 >&/dev/null; then
# We have color support; assume it's compliant with Ecma-48
# (ISO/IEC-6429). (Lack of such support is extremely rare, and such
# a case would tend to support setf rather than setaf.)
color_prompt=yes
else
color_prompt=
fi
fi
# load color variables
if [ -f ~/.bash_colors ]; then
. ~/.bash_colors
fi
# prompt
if [ "$color_prompt" = yes ]; then
PS1="${GREEN}ganymede@${BLUE}dawson:${ICYAN}\W${RESET}${IYELLOW} \$(parse_git_branch) $ "
else
PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ '
fi
unset color_prompt force_color_prompt
# get current branch in git repo
parse_git_branch() {
git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/ (\1)/'
}
# function parse_git_branch() {
# BRANCH=`git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/\1/'`
# if [ ! "${BRANCH}" == "" ]
# then
# STAT=`parse_git_dirty`
# echo "[${BRANCH}${STAT}]"
# else
# echo ""
# fi
# }
# file colors
LS_ORIGINAL=LS_COLORS
LS_COLORS='di=93:*.py=92:*.qml=92sb'
export LS_COLORS
# Alias definitions.
if [ -f ~/.bash_aliases ]; then
. ~/.bash_aliases
fi
# Alias functions.
if [ -f ~/.bash_functions ]; then
. ~/.bash_functions
fi
# virtual environment home
export WORKON_HOME='C:\Users\DawsonSchaffer\Documents\ProjectsDirectory\virtualenvirinments'
任何帮助都将不胜感激
谢谢
道森很抱歉,在扫描了几次文件后,我终于发现我的.bashrc中有一个时髦的角色。一旦我删除了它,它就可以正常工作了 谢谢 Dawson您需要在此处、您的问题中以及任何其他网站上发布一篇文章。