Add slides-bin/java and slides shell function
This commit is contained in:
parent
b1252955d6
commit
20c81522e4
|
@ -8,6 +8,14 @@ else
|
|||
alias pacman="sudo pacman"
|
||||
fi
|
||||
|
||||
alias _slides="$(which slides)"
|
||||
function slides() {
|
||||
OLD_PATH="$PATH"
|
||||
PATH="$HOME/.slides-bin:$PATH"
|
||||
_slides $@
|
||||
PATH="$OLD_PATH"
|
||||
}
|
||||
|
||||
function integrate {
|
||||
local from="$(realpath $1)"
|
||||
if [[ "$from" == "$f"* ]]; then
|
||||
|
|
|
@ -0,0 +1,14 @@
|
|||
#!/bin/bash
|
||||
|
||||
# Sometime around Java 23 or 24 this should all be stabilized
|
||||
|
||||
if [[ "$JAVA_21" == "" ]]; then
|
||||
echo '$JAVA_21 not defined!'
|
||||
exit 1
|
||||
fi
|
||||
|
||||
cp "$1" "/tmp/java.java" || exit 1
|
||||
|
||||
"$JAVA_21/bin/java" --source 21 --enable-preview "/tmp/java.java"
|
||||
|
||||
rm "/tmp/java.java"
|
Loading…
Reference in New Issue