diff options
| author | Filip Wandzio <contact@philw.dev> | 2026-02-05 13:17:14 +0100 |
|---|---|---|
| committer | Filip Wandzio <contact@philw.dev> | 2026-02-05 13:17:14 +0100 |
| commit | 3632aa92028a67bdff39340f1f58b27a5ec12c6e (patch) | |
| tree | f61bd75f69d8173d41467cd2bed10497f31b9468 /shell/.profile | |
| parent | a44dde93388f1c5c9ed6ea73d5e9ee7849e2d475 (diff) | |
| download | dotfiles-3632aa92028a67bdff39340f1f58b27a5ec12c6e.tar.gz dotfiles-3632aa92028a67bdff39340f1f58b27a5ec12c6e.zip | |
Diffstat (limited to 'shell/.profile')
| -rw-r--r-- | shell/.profile | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/shell/.profile b/shell/.profile new file mode 100644 index 0000000..0b0755f --- /dev/null +++ b/shell/.profile | |||
| @@ -0,0 +1,27 @@ | |||
| 1 | |||
| 2 | export XDG_DATA_HOME="$HOME/.local/share" | ||
| 3 | export XDG_CONFIG_HOME="$HOME/.config" | ||
| 4 | export XDG_STATE_HOME="$HOME/.local/state" | ||
| 5 | export XDG_CACHE_HOME="$HOME/.cache" | ||
| 6 | |||
| 7 | if [ -z "$XDG_RUNTIME_DIR" ]; then | ||
| 8 | export XDG_RUNTIME_DIR="/tmp/$(id -u)-runtime-dir" | ||
| 9 | mkdir -pm 0700 "$XDG_RUNTIME_DIR" | ||
| 10 | fi | ||
| 11 | |||
| 12 | export XAUTHORITY="$XDG_RUNTIME_DIR/Xauthority" | ||
| 13 | touch "$XAUTHORITY" | ||
| 14 | chmod 600 "$XAUTHORITY" | ||
| 15 | |||
| 16 | if [ -z "$DISPLAY" ] && [ "$(tty)" = "/dev/tty1" ]; then | ||
| 17 | exec startx "$XDG_CONFIG_HOME/x/xinitrc" | ||
| 18 | fi | ||
| 19 | |||
| 20 | case "$-" in | ||
| 21 | *i*) | ||
| 22 | if [ -z "$BASH_VERSION" ]; then | ||
| 23 | exec bash --login | ||
| 24 | fi | ||
| 25 | ;; | ||
| 26 | esac | ||
| 27 | |||
