mirror of
https://github.com/Smaug123/nix-dotfiles
synced 2025-10-13 02:18:42 +00:00
Add config for Earthworm (#19)
This commit is contained in:
21
home-manager/rider/link.sh
Normal file
21
home-manager/rider/link.sh
Normal file
@@ -0,0 +1,21 @@
|
||||
#!/bin/sh
|
||||
|
||||
outfile="$1/resharper-host/GlobalSettingsStorage.DotSettings"
|
||||
if [ -e "$outfile" ]; then
|
||||
existing=$(readlink "$outfile")
|
||||
if [ $? -eq 1 ] ; then
|
||||
echo "Backing up existing settings file $outfile"
|
||||
mv "$outfile" "$outfile.bak"
|
||||
ln -s "NIX-RIDER-CONFIG/GlobalSettingsStorage.DotSettings" "$outfile"
|
||||
else
|
||||
case "$existing" in
|
||||
"/nix/store/"*)
|
||||
ln -fs "NIX-RIDER-CONFIG/GlobalSettingsStorage.DotSettings" "$outfile" ;;
|
||||
*)
|
||||
echo "Refusing to overwrite existing symlink to $existing" && \
|
||||
exit 1 ;;
|
||||
esac
|
||||
fi
|
||||
else
|
||||
ln -s "NIX-RIDER-CONFIG/GlobalSettingsStorage.DotSettings" "$outfile"
|
||||
fi
|
Reference in New Issue
Block a user