-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #451 from machupicchubeta/move_apps_config_and_or_…
…data_dir_under_xdg_base_directory Move apps config and/or data directory under XDG Base Directory
- Loading branch information
Showing
18 changed files
with
137 additions
and
58 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,28 @@ | ||
export XDG_CONFIG_HOME="$HOME/.config" | ||
export XDG_CACHE_HOME="$HOME/.cache" | ||
export XDG_DATA_HOME="$HOME/.local/share" | ||
export XDG_STATE_HOME="$HOME/.local/state" | ||
|
||
if [ "$(uname -m)" = "x86_64" ]; then | ||
export ARCHFLAGS="-arch x86_64" | ||
export HOMEBREW_PREFIX="/usr/local" | ||
export HOMEBREW_CELLAR="/usr/local/Cellar" | ||
export HOMEBREW_REPOSITORY="/usr/local/Homebrew" | ||
export BUNDLE_USER_HOME="$HOME/.bundle_x86_64" | ||
|
||
export BUNDLE_USER_HOME="$XDG_DATA_HOME/bundle/x86_64" | ||
export BUNDLE_USER_CONFIG="$XDG_CONFIG_HOME/bundle/x86_64/config" | ||
export BUNDLE_USER_CACHE="$XDG_CACHE_HOME/bundle/x86_64" | ||
export BUNDLE_USER_PLUGIN="$XDG_DATA_HOME/bundle/x86_64/plugin" | ||
elif [ "$(uname -m)" = "arm64" ]; then | ||
export ARCHFLAGS="-arch arm64" | ||
export HOMEBREW_PREFIX="/opt/homebrew" | ||
export HOMEBREW_CELLAR="/opt/homebrew/Cellar" | ||
export HOMEBREW_REPOSITORY="/opt/homebrew" | ||
export BUNDLE_USER_HOME="$HOME/.bundle_arm64" | ||
|
||
export BUNDLE_USER_HOME="$XDG_DATA_HOME/bundle/arm64" | ||
export BUNDLE_USER_CONFIG="$XDG_CONFIG_HOME/bundle/arm64/config" | ||
export BUNDLE_USER_CACHE="$XDG_CACHE_HOME/bundle/arm64" | ||
export BUNDLE_USER_PLUGIN="$XDG_DATA_HOME/bundle/arm64/plugin" | ||
fi | ||
|
||
# Make vim the default editor | ||
|
@@ -24,8 +37,21 @@ export LESSOPEN="| $HOMEBREW_PREFIX/bin/src-hilite-lesspipe.sh %s" | |
export LC_ALL=en_US.UTF-8 | ||
export LANG=en_US.UTF-8 | ||
|
||
export PYENV_ROOT="$HOME/.pyenv" | ||
export PATH="$HOMEBREW_PREFIX/opt/libxml2/bin:$HOMEBREW_PREFIX/opt/libxslt/bin:$HOMEBREW_PREFIX/opt/libiconv/bin:$HOMEBREW_PREFIX/opt/openssl/bin:$HOMEBREW_PREFIX/opt/libressl/bin:$HOMEBREW_PREFIX/opt/curl/bin:$HOMEBREW_PREFIX/opt/sqlite/bin:$HOMEBREW_PREFIX/opt/nss/bin:$HOMEBREW_PREFIX/opt/ruby/bin:$HOMEBREW_PREFIX/opt/go/bin:$HOMEBREW_PREFIX/opt/python/bin:$HOMEBREW_PREFIX/opt/python/libexec/bin:$HOMEBREW_PREFIX/opt/openjdk/bin:$HOMEBREW_PREFIX/opt/coreutils/libexec/gnubin:$HOMEBREW_PREFIX/opt/ed/libexec/gnubin:$HOMEBREW_PREFIX/opt/ed/bin:$HOMEBREW_PREFIX/opt/findutils/libexec/gnubin:$HOMEBREW_PREFIX/opt/gnu-indent/libexec/gnubin:$HOMEBREW_PREFIX/opt/gnu-sed/libexec/gnubin:$HOMEBREW_PREFIX/opt/gnu-tar/libexec/gnubin:$HOMEBREW_PREFIX/opt/gnu-which/libexec/gnubin:$HOMEBREW_PREFIX/opt/gnu-getopt/bin:$HOMEBREW_PREFIX/opt/grep/libexec/gnubin:$HOMEBREW_PREFIX/opt/m4/bin:$HOMEBREW_PREFIX/opt/make/libexec/gnubin:$HOMEBREW_PREFIX/opt/file-formula/bin:$HOMEBREW_PREFIX/opt/apr/bin:$HOMEBREW_PREFIX/opt/unzip/bin:$HOMEBREW_PREFIX/opt/ssh-copy-id/bin:$HOMEBREW_PREFIX/opt/util-linux/bin:$HOMEBREW_PREFIX/opt/util-linux/sbin:$HOMEBREW_PREFIX/opt/postgresql@16/bin:$HOME/bin:$HOME/.cargo/bin:$PYENV_ROOT/bin:$HOMEBREW_PREFIX/bin:$HOMEBREW_PREFIX/sbin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin" | ||
export STARSHIP_CONFIG="$XDG_CONFIG_HOME/starship/config.toml" | ||
export STARSHIP_CACHE="$XDG_CACHE_HOME/starship" | ||
export INPUTRC="$XDG_CONFIG_HOME/readline/inputrc" | ||
export RBENV_ROOT="$XDG_DATA_HOME/rbenv" | ||
export IRBRC="$XDG_CONFIG_HOME/irb/irbrc" | ||
export RUSTUP_HOME="$XDG_DATA_HOME/rustup" | ||
export CARGO_HOME="$XDG_DATA_HOME/cargo" | ||
export _Z_DATA="$XDG_DATA_HOME/z/data" | ||
export NODENV_ROOT="$XDG_DATA_HOME/nodenv" | ||
export PYENV_ROOT="$XDG_DATA_HOME/pyenv" | ||
export GOENV_ROOT="$XDG_DATA_HOME/goenv" | ||
export GOENV_GOPATH_PREFIX="$XDG_DATA_HOME/goenv/modules" | ||
export ENHANCD_DIR="$XDG_DATA_HOME/enhancd" | ||
|
||
export PATH="$GOENV_ROOT/shims:$HOMEBREW_PREFIX/opt/libxml2/bin:$HOMEBREW_PREFIX/opt/libxslt/bin:$HOMEBREW_PREFIX/opt/libiconv/bin:$HOMEBREW_PREFIX/opt/openssl/bin:$HOMEBREW_PREFIX/opt/libressl/bin:$HOMEBREW_PREFIX/opt/curl/bin:$HOMEBREW_PREFIX/opt/sqlite/bin:$HOMEBREW_PREFIX/opt/nss/bin:$HOMEBREW_PREFIX/opt/ruby/bin:$HOMEBREW_PREFIX/opt/go/bin:$HOMEBREW_PREFIX/opt/python/bin:$HOMEBREW_PREFIX/opt/python/libexec/bin:$HOMEBREW_PREFIX/opt/openjdk/bin:$HOMEBREW_PREFIX/opt/coreutils/libexec/gnubin:$HOMEBREW_PREFIX/opt/ed/libexec/gnubin:$HOMEBREW_PREFIX/opt/ed/bin:$HOMEBREW_PREFIX/opt/findutils/libexec/gnubin:$HOMEBREW_PREFIX/opt/gnu-indent/libexec/gnubin:$HOMEBREW_PREFIX/opt/gnu-sed/libexec/gnubin:$HOMEBREW_PREFIX/opt/gnu-tar/libexec/gnubin:$HOMEBREW_PREFIX/opt/gnu-which/libexec/gnubin:$HOMEBREW_PREFIX/opt/gnu-getopt/bin:$HOMEBREW_PREFIX/opt/grep/libexec/gnubin:$HOMEBREW_PREFIX/opt/m4/bin:$HOMEBREW_PREFIX/opt/make/libexec/gnubin:$HOMEBREW_PREFIX/opt/file-formula/bin:$HOMEBREW_PREFIX/opt/apr/bin:$HOMEBREW_PREFIX/opt/unzip/bin:$HOMEBREW_PREFIX/opt/ssh-copy-id/bin:$HOMEBREW_PREFIX/opt/util-linux/bin:$HOMEBREW_PREFIX/opt/util-linux/sbin:$HOMEBREW_PREFIX/opt/postgresql@16/bin:$HOME/bin:$CARGO_HOME/bin:$PYENV_ROOT/bin:$HOMEBREW_PREFIX/bin:$HOMEBREW_PREFIX/sbin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin" | ||
if [ -n "$(echo $CPU_BRAND | grep -o 'Apple')" -a "$(uname -m)" = "arm64" ]; then | ||
export PATH="$PATH:/usr/local/bin" | ||
fi | ||
|
@@ -49,11 +75,6 @@ export AWS_PROFILE=default | |
|
||
export DISABLE_SPRING=1 | ||
|
||
export XDG_CONFIG_HOME="$HOME/.config" | ||
export XDG_CACHE_HOME="$HOME/.cache" | ||
export XDG_DATA_HOME="$HOME/.local/share" | ||
export XDG_STATE_HOME="$HOME/.local/state" | ||
|
||
export PYTHONPATH=$(if [ -d "$PYENV_ROOT/shims" ]; then echo "$PYENV_ROOT/shims"; elif [ -d "$HOMEBREW_PREFIX/opt/python/libexec/bin" ]; then echo "$HOMEBREW_PREFIX/opt/python/libexec/bin"; else echo '/usr/bin/python'; fi) | ||
|
||
export ENHANCD_FILTER=fzf | ||
|
@@ -65,6 +86,4 @@ export GUILE_TLS_CERTIFICATE_DIRECTORY="$HOMEBREW_PREFIX/etc/gnutls/" | |
|
||
export RUBY_CONFIGURE_OPTS="--with-openssl-dir=$HOMEBREW_PREFIX/opt/[email protected]" | ||
|
||
export STARSHIP_CONFIG="$XDG_CONFIG_HOME/starship/config.toml" | ||
|
||
export GPG_TTY=$(tty) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,28 @@ | ||
export XDG_CONFIG_HOME="$HOME/.config" | ||
export XDG_CACHE_HOME="$HOME/.cache" | ||
export XDG_DATA_HOME="$HOME/.local/share" | ||
export XDG_STATE_HOME="$HOME/.local/state" | ||
|
||
if [ "$(uname -m)" = "x86_64" ]; then | ||
export ARCHFLAGS="-arch x86_64" | ||
export HOMEBREW_PREFIX="/usr/local" | ||
export HOMEBREW_CELLAR="/usr/local/Cellar" | ||
export HOMEBREW_REPOSITORY="/usr/local/Homebrew" | ||
export BUNDLE_USER_HOME="$HOME/.bundle_x86_64" | ||
|
||
export BUNDLE_USER_HOME="$XDG_DATA_HOME/bundle/x86_64" | ||
export BUNDLE_USER_CONFIG="$XDG_CONFIG_HOME/bundle/x86_64/config" | ||
export BUNDLE_USER_CACHE="$XDG_CACHE_HOME/bundle/x86_64" | ||
export BUNDLE_USER_PLUGIN="$XDG_DATA_HOME/bundle/x86_64/plugin" | ||
elif [ "$(uname -m)" = "arm64" ]; then | ||
export ARCHFLAGS="-arch arm64" | ||
export HOMEBREW_PREFIX="/opt/homebrew" | ||
export HOMEBREW_CELLAR="/opt/homebrew/Cellar" | ||
export HOMEBREW_REPOSITORY="/opt/homebrew" | ||
export BUNDLE_USER_HOME="$HOME/.bundle_arm64" | ||
|
||
export BUNDLE_USER_HOME="$XDG_DATA_HOME/bundle/arm64" | ||
export BUNDLE_USER_CONFIG="$XDG_CONFIG_HOME/bundle/arm64/config" | ||
export BUNDLE_USER_CACHE="$XDG_CACHE_HOME/bundle/arm64" | ||
export BUNDLE_USER_PLUGIN="$XDG_DATA_HOME/bundle/arm64/plugin" | ||
fi | ||
|
||
export CPU_BRAND="$(/usr/sbin/sysctl -n machdep.cpu.brand_string)" | ||
|
@@ -27,8 +40,21 @@ export LESSOPEN="| $HOMEBREW_PREFIX/bin/src-hilite-lesspipe.sh %s" | |
export LC_ALL=en_US.UTF-8 | ||
export LANG=en_US.UTF-8 | ||
|
||
export PYENV_ROOT="$HOME/.pyenv" | ||
export PATH="$HOMEBREW_PREFIX/opt/libxml2/bin:$HOMEBREW_PREFIX/opt/libxslt/bin:$HOMEBREW_PREFIX/opt/libiconv/bin:$HOMEBREW_PREFIX/opt/openssl/bin:$HOMEBREW_PREFIX/opt/libressl/bin:$HOMEBREW_PREFIX/opt/curl/bin:$HOMEBREW_PREFIX/opt/sqlite/bin:$HOMEBREW_PREFIX/opt/nss/bin:$HOMEBREW_PREFIX/opt/ruby/bin:$HOMEBREW_PREFIX/opt/go/bin:$HOMEBREW_PREFIX/opt/python/bin:$HOMEBREW_PREFIX/opt/python/libexec/bin:$HOMEBREW_PREFIX/opt/openjdk/bin:$HOMEBREW_PREFIX/opt/coreutils/libexec/gnubin:$HOMEBREW_PREFIX/opt/ed/libexec/gnubin:$HOMEBREW_PREFIX/opt/ed/bin:$HOMEBREW_PREFIX/opt/findutils/libexec/gnubin:$HOMEBREW_PREFIX/opt/gnu-indent/libexec/gnubin:$HOMEBREW_PREFIX/opt/gnu-sed/libexec/gnubin:$HOMEBREW_PREFIX/opt/gnu-tar/libexec/gnubin:$HOMEBREW_PREFIX/opt/gnu-which/libexec/gnubin:$HOMEBREW_PREFIX/opt/gnu-getopt/bin:$HOMEBREW_PREFIX/opt/grep/libexec/gnubin:$HOMEBREW_PREFIX/opt/m4/bin:$HOMEBREW_PREFIX/opt/make/libexec/gnubin:$HOMEBREW_PREFIX/opt/file-formula/bin:$HOMEBREW_PREFIX/opt/apr/bin:$HOMEBREW_PREFIX/opt/unzip/bin:$HOMEBREW_PREFIX/opt/ssh-copy-id/bin:$HOMEBREW_PREFIX/opt/util-linux/bin:$HOMEBREW_PREFIX/opt/util-linux/sbin:$HOMEBREW_PREFIX/opt/postgresql@16/bin:$HOME/bin:$HOME/.docker/bin:$HOME/.cargo/bin:$PYENV_ROOT/bin:$HOMEBREW_PREFIX/bin:$HOMEBREW_PREFIX/sbin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin" | ||
export STARSHIP_CONFIG="$XDG_CONFIG_HOME/starship/config.toml" | ||
export STARSHIP_CACHE="$XDG_CACHE_HOME/starship" | ||
export INPUTRC="$XDG_CONFIG_HOME/readline/inputrc" | ||
export RBENV_ROOT="$XDG_DATA_HOME/rbenv" | ||
export IRBRC="$XDG_CONFIG_HOME/irb/irbrc" | ||
export RUSTUP_HOME="$XDG_DATA_HOME/rustup" | ||
export CARGO_HOME="$XDG_DATA_HOME/cargo" | ||
export _Z_DATA="$XDG_DATA_HOME/z/data" | ||
export NODENV_ROOT="$XDG_DATA_HOME/nodenv" | ||
export PYENV_ROOT="$XDG_DATA_HOME/pyenv" | ||
export GOENV_ROOT="$XDG_DATA_HOME/goenv" | ||
export GOENV_GOPATH_PREFIX="$XDG_DATA_HOME/goenv/modules" | ||
export ENHANCD_DIR="$XDG_DATA_HOME/enhancd" | ||
|
||
export PATH="$GOENV_ROOT/shims:$HOMEBREW_PREFIX/opt/libxml2/bin:$HOMEBREW_PREFIX/opt/libxslt/bin:$HOMEBREW_PREFIX/opt/libiconv/bin:$HOMEBREW_PREFIX/opt/openssl/bin:$HOMEBREW_PREFIX/opt/libressl/bin:$HOMEBREW_PREFIX/opt/curl/bin:$HOMEBREW_PREFIX/opt/sqlite/bin:$HOMEBREW_PREFIX/opt/nss/bin:$HOMEBREW_PREFIX/opt/ruby/bin:$HOMEBREW_PREFIX/opt/go/bin:$HOMEBREW_PREFIX/opt/python/bin:$HOMEBREW_PREFIX/opt/python/libexec/bin:$HOMEBREW_PREFIX/opt/openjdk/bin:$HOMEBREW_PREFIX/opt/coreutils/libexec/gnubin:$HOMEBREW_PREFIX/opt/ed/libexec/gnubin:$HOMEBREW_PREFIX/opt/ed/bin:$HOMEBREW_PREFIX/opt/findutils/libexec/gnubin:$HOMEBREW_PREFIX/opt/gnu-indent/libexec/gnubin:$HOMEBREW_PREFIX/opt/gnu-sed/libexec/gnubin:$HOMEBREW_PREFIX/opt/gnu-tar/libexec/gnubin:$HOMEBREW_PREFIX/opt/gnu-which/libexec/gnubin:$HOMEBREW_PREFIX/opt/gnu-getopt/bin:$HOMEBREW_PREFIX/opt/grep/libexec/gnubin:$HOMEBREW_PREFIX/opt/m4/bin:$HOMEBREW_PREFIX/opt/make/libexec/gnubin:$HOMEBREW_PREFIX/opt/file-formula/bin:$HOMEBREW_PREFIX/opt/apr/bin:$HOMEBREW_PREFIX/opt/unzip/bin:$HOMEBREW_PREFIX/opt/ssh-copy-id/bin:$HOMEBREW_PREFIX/opt/util-linux/bin:$HOMEBREW_PREFIX/opt/util-linux/sbin:$HOMEBREW_PREFIX/opt/postgresql@16/bin:$HOME/bin:$HOME/.docker/bin:$CARGO_HOME/bin:$PYENV_ROOT/bin:$HOMEBREW_PREFIX/bin:$HOMEBREW_PREFIX/sbin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin" | ||
if [ -n "$(echo $CPU_BRAND | grep -o 'Apple')" -a "$(uname -m)" = "arm64" ]; then | ||
export PATH="$PATH:/usr/local/bin" | ||
fi | ||
|
@@ -53,12 +79,6 @@ export AWS_PROFILE=default | |
|
||
export DISABLE_SPRING=1 | ||
|
||
export XDG_CONFIG_HOME="$HOME/.config" | ||
export XDG_CACHE_HOME="$HOME/.cache" | ||
export XDG_DATA_HOME="$HOME/.local/share" | ||
export XDG_STATE_HOME="$HOME/.local/state" | ||
|
||
export RBENV_ROOT="$HOME/.rbenv" | ||
export GHQ_ROOT="$HOME/Repositories" | ||
|
||
export PYTHONPATH=$(if [ -d "$PYENV_ROOT/shims" ]; then echo "$PYENV_ROOT/shims"; elif [ -d "$HOMEBREW_PREFIX/opt/python/libexec/bin" ]; then echo "$HOMEBREW_PREFIX/opt/python/libexec/bin"; else echo '/usr/bin/python'; fi) | ||
|
@@ -74,6 +94,4 @@ export RUBY_CONFIGURE_OPTS="--with-openssl-dir=$HOMEBREW_PREFIX/opt/[email protected]" | |
|
||
export ZSH_AUTOSUGGEST_HIGHLIGHT_STYLE="fg=#F2E6D4,bg=#7E87D6,bold,underline" | ||
|
||
export STARSHIP_CONFIG="$XDG_CONFIG_HOME/starship/config.toml" | ||
|
||
export GPG_TTY=$(tty) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,19 @@ | ||
#!/bin/bash | ||
set -eu | ||
|
||
: "${XDG_DATA_HOME:=$HOME/.local/share}" | ||
: "${RUSTUP_HOME:=$XDG_DATA_HOME/rustup}" | ||
: "${CARGO_HOME:=$XDG_DATA_HOME/cargo}" | ||
|
||
# if [[ ! -d "$HOME/.cargo/bin" ]]; then RUSTUP_INIT_SKIP_PATH_CHECK=yes rustup-init -y --no-modify-path --default-host x86_64-apple-darwin --default-toolchain stable --profile default; fi | ||
if [[ ! -d "$HOME/.cargo/bin" ]]; then RUSTUP_INIT_SKIP_PATH_CHECK=yes rustup-init -y --no-update-default-toolchain --no-modify-path; fi | ||
if [[ ! -d "$CARGO_HOME/bin" ]]; then RUSTUP_INIT_SKIP_PATH_CHECK=yes rustup-init -y --no-update-default-toolchain --no-modify-path; fi | ||
rustup update | ||
|
||
if [ "$(uname -m)" = "x86_64" ]; then | ||
: "${HOMEBREW_PREFIX:=/usr/local}" | ||
elif [ "$(uname -m)" = "arm64" ]; then | ||
: "${HOMEBREW_PREFIX:=/opt/homebrew}" | ||
fi | ||
if [[ ! -f $HOMEBREW_PREFIX/etc/bash_completion.d/rustup.bash-completion ]]; then rustup completions bash > $HOMEBREW_PREFIX/etc/bash_completion.d/rustup.bash-completion; fi | ||
if [[ ! -d "$HOME/.zfunc" ]]; then mkdir -p "$HOME/.zfunc"; fi | ||
if [[ ! -f $HOME/.zfunc/_rustup ]]; then rustup completions zsh > $HOME/.zfunc/_rustup; fi | ||
if [[ ! -f "$HOMEBREW_PREFIX/etc/bash_completion.d/rustup.bash-completion" ]]; then rustup completions bash > "$HOMEBREW_PREFIX/etc/bash_completion.d/rustup.bash-completion"; fi | ||
if [[ ! -d "$RUSTUP_HOME" ]]; then mkdir -p "$RUSTUP_HOME"; fi | ||
if [[ ! -f "$RUSTUP_HOME/completions" ]]; then rustup completions zsh > "$RUSTUP_HOME/completions"; fi |
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
# frozen_string_literal: true | ||
|
||
autoload :Base64, 'base64' | ||
autoload :CGI, 'cgi' | ||
autoload :CSV, 'csv' | ||
autoload :Digest, 'digest' | ||
autoload :ERB, 'erb' | ||
autoload :FileUtils, 'fileutils' | ||
autoload :JSON, 'json' | ||
autoload :Pathname, 'pathname' | ||
autoload :Psych, 'psych' | ||
autoload :Ripper, 'ripper' | ||
autoload :SecureRandom, 'securerandom' | ||
autoload :Shellwords, 'shellwords' | ||
autoload :StringIO, 'stringio' | ||
autoload :URI, 'uri/generic' # `autoload :URI, 'uri'` breaks Rails | ||
autoload :YAML, 'yaml' | ||
autoload :Zlib, 'zlib' | ||
|
||
IRB.conf[:USE_AUTOCOMPLETE] = false | ||
IRB.conf[:SAVE_HISTORY] = 1000 | ||
IRB.conf[:HISTORY_FILE] = File.join(ENV['XDG_DATA_HOME'], 'irb', 'history') | ||
if defined?(IRB::Color) # just for consistency | ||
clear = "\e[0m" | ||
bold = "\e[1m" | ||
green = "\e[32m" | ||
blue = "\e[34m" | ||
cyan = "\e[36m" | ||
IRB.conf[:PROMPT][:DEFAULT] = { | ||
PROMPT_I: "#{cyan}#{bold}%N#{clear}(#{green}#{bold}%m#{clear})[#{blue}%02n#{clear}:%i]> ", | ||
PROMPT_N: "#{cyan}#{bold}%N#{clear}(#{green}#{bold}%m#{clear})[#{blue}%02n#{clear}:%i]> ", | ||
PROMPT_S: "#{cyan}#{bold}%N#{clear}(#{green}#{bold}%m#{clear})[#{blue}%02n#{clear}:%i]%l ", | ||
PROMPT_C: "#{cyan}#{bold}%N#{clear}(#{green}#{bold}%m#{clear})[#{blue}%02n#{clear}:%i]* ", | ||
RETURN: "=> %s\n", | ||
} | ||
end |
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.