Created
January 8, 2021 22:09
-
-
Save jon-zu/5b8c9756fb219de31f80643c3efa03f5 to your computer and use it in GitHub Desktop.
Allows to use dotnet 3.1 and dotnet 5.0 runtime together on Fedora(probably all RHEL derivates)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
LINK_PATH=/usr/lib64/dotnet/shared | |
LINK_VER=3.1.10 | |
TARGET_PATH=/usr/share/dotnet/shared | |
link() { | |
ln -s "$LINK_PATH/Microsoft.AspNetCore.App/$LINK_VER" "$TARGET_PATH/Microsoft.AspNetCore.App/$LINK_VER" | |
ln -s "$LINK_PATH/Microsoft.NETCore.App/$LINK_VER" "$TARGET_PATH/Microsoft.NETCore.App/$LINK_VER" | |
} | |
unlink_dotnet() { | |
unlink "$TARGET_PATH/Microsoft.AspNetCore.App/$LINK_VER" | |
unlink "$TARGET_PATH/Microsoft.NETCore.App/$LINK_VER" | |
} | |
case "$1" in | |
unlink) unlink_dotnet ;; | |
*) link | |
esac |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment