Streamline aliae installation

This commit is contained in:
Manuel Thalmann 2024-07-16 03:30:14 +02:00
parent a761514d2a
commit 5e5bb3e5df
9 changed files with 114 additions and 2 deletions
scripts/Common/Scripts

View file

@ -0,0 +1,23 @@
#!/bin/env fish
begin
function processContent -a content
echo "$content"
end
function addProfileStatement -a name title shellBin extension profileRoot content
set -l file (mktemp)
if [ -z "$content" ]
read -l content
end
begin
printf %s\n \
"#!$shellBin" \
"# $title" \
(processContent "$content")
end > "$file"
sudo install -Dm755 "$file" "$profileRoot/$name.$extension"
end
end