From ecd7cd1085b6752ff4b4768a5e87676d47d74148 Mon Sep 17 00:00:00 2001 From: Alex Kotov Date: Tue, 29 Oct 2024 06:12:19 +0400 Subject: [PATCH] fish: login shell to read "/etc/profile" and "~/.profile" --- files.sh | 4 ++++ openbsd/etc/man.conf | 0 openbsd/etc/profile | 5 +++++ openbsd/etc/profile.d/autotools.sh | 2 ++ openbsd/etc/shells | 12 ++++++++++++ openbsd/usr/local/bin/fish-login | 3 +++ 6 files changed, 26 insertions(+) mode change 100755 => 100644 openbsd/etc/man.conf create mode 100644 openbsd/etc/profile create mode 100644 openbsd/etc/profile.d/autotools.sh create mode 100644 openbsd/etc/shells create mode 100755 openbsd/usr/local/bin/fish-login diff --git a/files.sh b/files.sh index 193c5e1..fd957c4 100644 --- a/files.sh +++ b/files.sh @@ -54,4 +54,8 @@ fi if [ "$PREFIX" = 'openbsd' ]; then echo install_file openbsd root wheel 644 '/etc/man.conf' +install_dir root wheel 755 '/etc/profile.d' +install_file openbsd root wheel 644 '/etc/profile.d/autotools.sh' +install_file openbsd root wheel 644 '/etc/shells' +install_file openbsd root bin 755 '/usr/local/bin/fish-login' fi diff --git a/openbsd/etc/man.conf b/openbsd/etc/man.conf old mode 100755 new mode 100644 diff --git a/openbsd/etc/profile b/openbsd/etc/profile new file mode 100644 index 0000000..283a5dc --- /dev/null +++ b/openbsd/etc/profile @@ -0,0 +1,5 @@ +for f in /etc/profile.d/*.sh; do + if [ -f "$f" -a -r "$f" ]; then + . "$f" + fi +done diff --git a/openbsd/etc/profile.d/autotools.sh b/openbsd/etc/profile.d/autotools.sh new file mode 100644 index 0000000..9945f39 --- /dev/null +++ b/openbsd/etc/profile.d/autotools.sh @@ -0,0 +1,2 @@ +export AUTOCONF_VERSION='2.72' +export AUTOMAKE_VERSION='1.16' diff --git a/openbsd/etc/shells b/openbsd/etc/shells new file mode 100644 index 0000000..ba75d57 --- /dev/null +++ b/openbsd/etc/shells @@ -0,0 +1,12 @@ +# $OpenBSD: shells,v 1.8 2009/02/14 17:06:40 sobrado Exp $ +# +# list of acceptable shells for chpass(1). +# ftpd(8) will not allow users to connect who are not using +# one of these shells, unless the user is listed in /etc/ftpchroot. +/bin/sh +/bin/csh +/bin/ksh +/usr/local/bin/git-shell +/usr/local/bin/fish +/usr/local/bin/fish-login +/usr/local/bin/bash diff --git a/openbsd/usr/local/bin/fish-login b/openbsd/usr/local/bin/fish-login new file mode 100755 index 0000000..86470b2 --- /dev/null +++ b/openbsd/usr/local/bin/fish-login @@ -0,0 +1,3 @@ +#!/bin/ksh -l + +exec /usr/local/bin/fish "$@"