small shell funcs

This commit is contained in:
cscherr 2025-08-04 17:08:54 +02:00
parent 0d71b8c365
commit 5d5b94e6f3
Signed by: cscherrNT
GPG key ID: 8E2B45BC51A27EA7

11
.zshrc
View file

@ -86,6 +86,17 @@ function condac() {
conda activate $@ conda activate $@
export HOST=$(hostname) export HOST=$(hostname)
} }
function k()
{
echo -n "$(( $@ ))"
}
function rscript ()
{
TDIR=$(mktemp -d)
rustc -v -C lto -C opt-level=3 $1 -o $TDIR/rscript_executable
$TDIR/rscript_executable ${@:2}
rm -rf $TDIR
}
# Call Python and execute multiple statements from args # Call Python and execute multiple statements from args
function py() { function py() {
python <<< " python <<< "