mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2024-11-22 05:40:08 +00:00
For unspecified encodings, assume it's UTF-8 or compatible (e.g. ASCII) and muddle through without character encoding conversion.
This commit is contained in:
parent
702ff1ca91
commit
187cf07c91
1 changed files with 1 additions and 1 deletions
|
@ -69,7 +69,7 @@ if [[ "$TERM_PROGRAM" == "Apple_Terminal" ]] && [[ -z "$INSIDE_EMACS" ]]; then
|
|||
|
||||
# URLs must use UTF-8 encoding; convert if required
|
||||
local encoding=${LC_CTYPE/*./}
|
||||
if [[ $encoding != UTF-8 ]]; then
|
||||
if [[ -n $encoding && $encoding != UTF-8 ]]; then
|
||||
str=$(iconv -f $encoding -t UTF-8)
|
||||
if [[ $? != 0 ]]; then
|
||||
echo "Error converting string from $encoding to UTF-8" >&2
|
||||
|
|
Loading…
Reference in a new issue