diff --git a/pkgs/lazybox/build.sh b/pkgs/lazybox/build.sh index 218c17a..899ebfd 100644 --- a/pkgs/lazybox/build.sh +++ b/pkgs/lazybox/build.sh @@ -7,6 +7,7 @@ ext="dev" fetch() { mkdir $pkgname-$pkgver + cp ../profile.sh . cd $pkgname-$pkgver cp ../../../../lazy*.sh . cp ../../../../LICENSE . @@ -19,6 +20,8 @@ build() { package() { cd $pkgname-$pkgver + install -d $pkgdir/etc/ + install -Dm644 ../profile.sh $pkgdir/etc/profile install -d $pkgdir/usr/sbin install -Dm755 lazy.sh $pkgdir/usr/sbin/lazy } diff --git a/pkgs/lazybox/profile.sh b/pkgs/lazybox/profile.sh new file mode 100644 index 0000000..4b2f6e4 --- /dev/null +++ b/pkgs/lazybox/profile.sh @@ -0,0 +1,20 @@ +# Setup Path +export PATH=/usr/sbin:/usr/bin:/sbin:/bin +export POSIX_ME_HARDER=1 + +# Setup Shell Prompt +if [ "$(whoami)" == "root" ]; then + export PS1=$(hostname)"# " +else + export PS1=$(hostname)"$ " +fi + +# Replace TERM with xterm because netbsd-curses doesn't include alacritty +if [ "$TERM" == "alacritty" ]; then + export TERM=xterm +fi + +# load profile +for file in $(ls /etc/profile.d); do + . /etc/profile.d/$file +done