XDG
X Desktop Group
사용자 디렉토리 설정[편집 | 원본 편집]
음악, 사진, 동영상, 문서, 다운로드 등의 사용자 디렉토리를 설정한다.
~/.config/user-dirs.dirs
$ xdg-user-dirs-gtk-update
기본값으로 변경하기[편집 | 원본 편집]
$ export LANG=C
$ xdg-user-dirs-gtk-update
LANG 을 "C" 로 설정하는 건 locale을 끄는 의미이고 "C" 는 표준에 있는 locale name 이 맞다고 한다.
locale name 이 "C" 인 것은 C 언어 표준 중 7.11.1.1 The setlocale function 에 다음과 같이 지정되어 있기 때문이다. (C 언어 표준에 있는 내용이라 "C" 인 것 같다)
기본 프로그램 설정[편집 | 원본 편집]
$HOME/.config/mimeapps.list
mime형식 조회[편집 | 원본 편집]
$ xdg-mime query filetype 파일명
기본 프로그램 조회[편집 | 원본 편집]
$ xdg-mime query default application/x-bittorrent
기본 프로그램 변경[편집 | 원본 편집]
$ xdg-mime default transgui.desktop application/x-bittorrent
desktop확장자를 가진 파일들은 /usr/share/applications 에 위치한다. 마그넷링크를 transgui에 설정한다면
$ xdg-mime default transgui.desktop x-scheme-handler/magnet
외부링크[편집 | 원본 편집]
https://www.freedesktop.org/wiki/Specifications/mime-apps-spec/