gitreef

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | README | LICENSE

commit 7744f8f14d045d5da0fd0f8a7bb58241dff2d758
parent 0ed23b92c74945545e97bdd455b4ac3b6564941a
Author: Matthias Jaros <jaros@mailbox.org>
Date:   Sun, 30 Nov 2025 12:27:02 +0100

Comments

Diffstat:
Msrc/git-run | 15+++++++++++++--
Msrc/init | 22+++++++++++-----------
2 files changed, 24 insertions(+), 13 deletions(-)

diff --git a/src/git-run b/src/git-run @@ -1,13 +1,18 @@ #!/usr/bin/env fish -# load environment +# load common environment source (status dirname)/env -# global variables set gitCommand set repoDir set currentUser (whoami) +### +### +### functions +### +### + function log --on-event log echo "$(date -Is): $argv[1..2] user=$currentUser $argv[3..] ip=$SSH_CONNECTION" >> $_LOG end @@ -62,6 +67,12 @@ function verifyPermissions end end +### +### +### main +### +### + # redirect stdout/stderr to file, no information to potential attacker begin parseCommand $argv; or exit $status diff --git a/src/init b/src/init @@ -1,13 +1,13 @@ #!/usr/bin/env fish -# load environment +# load common environment source (status dirname)/env -# -# -# function definitions -# -# +### +### +### functions +### +### function fail set_color red @@ -110,11 +110,11 @@ function setupSSH mkdir -p /var/ssh/etc/ssh/ && ssh-keygen -A -f /var/ssh end -# -# -# main -# -# +### +### +### main +### +### argparse 'g/git-uid=?' 'u/user=+' 'r/repo=+' 'h/help' 'v/version' -- $argv or exit 1;