# utf8-profile

## Description:

로컬 문자셋과 UTF-8간의 전환을 위할 프로파일

## Features:

1. /etc/sysconfig/utf8-profile 에 지정되어 있는 문자셋과 UTF-8간의 LANG 환경 변수 전환 alias 제공

## Reference:

* /etc/profile.d/utf8.sh
* /etc/sysconfig/utf8-profile

```bash
[root@an3 x86_64]$ alias u
alias u='shopt -s nocasematch; [[ "$LANG" =~ \.utf[-]?8$ ]] && [ "$OLD_LANG" != "$CONVERSION_LANG" ] && OLD_LANG="${CONVERSION_LANG}" ; [[ "$LANG" =~ \.utf[-]?8$ ]] && NEW_LANG="${OLD_LANG:=${CONVERSION_LANG}}" || NEW_LANG="${LANG%%.*}.UTF-8"; export OLD_LANG="$LANG" && export LANG="$NEW_LANG" && export USER_LANG="$NEW_LANG" && export LC_ALL="$NEW_LANG"; echo "Changed system charset to {${LANG}}"; shopt -u nocasematch'
[root@an3 x86_64]$ cat /etc/sysconfig/utf8-profile
# Locale conversion configuration
#
# /etc/profile.d/utf8.sh
#     conversion between UTF-8 and CONVERSION_LANG
#

CONVERSION_LANG="ko_KR.eucKR"
[root@an3 x86_64]$ u
Changed system charset to {ko_KR.eucKR}
[root@an3 x86_64]$ echo $LANG
ko_KR.eucKR
[root@an3 x86_64]$ u
Changed system charset to {ko_KR.UTF-8}
[root@an3 x86_64]$ echo $LANG
ko_KR.UTF-8
```

## Dependencies:

* None

## Sub Packages:

* None

## Releated Packages:

* None


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://joungkyun.gitbook.io/annyung-3-user-guide/annyung3-package-catalog/annyung3-core-packages/pkg-core-utf8-profile.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
