Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions scripts/post-install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,17 @@
# Author: hustcer
# Created: 2025/02/25 18:55:20

set -e

# Running nu in the rpm-ostree script environment fails if the config directory
# doesn't exist, preventing the post-install.nu script from being run.
if [ -n "${XDG_CONFIG_HOME+x}" ]; then
mkdir -p "$XDG_CONFIG_HOME"
elif [ -n "${HOME+x}" ]; then
mkdir -p "$HOME/.config"
else
export XDG_CONFIG_HOME="$PWD/.config"
mkdir -p "$XDG_CONFIG_HOME"
fi

nu /usr/libexec/nushell/post-install.nu
13 changes: 13 additions & 0 deletions scripts/pre-remove.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,17 @@
# Author: hustcer
# Created: 2025/03/10 08:35:20

set -e

# Running nu in the rpm-ostree script environment fails if the config directory
# doesn't exist, preventing the pre-remove.nu script from being run.
if [ -n "${XDG_CONFIG_HOME+x}" ]; then
mkdir -p "$XDG_CONFIG_HOME"
elif [ -n "${HOME+x}" ]; then
mkdir -p "$HOME/.config"
else
export XDG_CONFIG_HOME="$PWD/.config"
mkdir -p "$XDG_CONFIG_HOME"
fi

nu /usr/libexec/nushell/pre-remove.nu
Loading