mirror of
https://github.com/nmasur/dotfiles
synced 2025-07-05 08:00:14 +00:00
rust-analyzer automation
This commit is contained in:
19
scripts/update_rust_analyzer
Executable file
19
scripts/update_rust_analyzer
Executable file
@ -0,0 +1,19 @@
|
||||
#!/bin/sh
|
||||
|
||||
update_rust_analyzer() {
|
||||
if ! (which rust-analyzer > /dev/null)
|
||||
then
|
||||
echo "not installed"
|
||||
else
|
||||
echo "removing"
|
||||
rm /usr/local/bin/rust-analyzer
|
||||
fi
|
||||
echo "downloading rust analyzer"
|
||||
rust_analyzer_bin=/usr/local/bin/rust-analyzer
|
||||
curl -s -L https://github.com/rust-analyzer/rust-analyzer/releases/latest/download/rust-analyzer-mac -o $rust_analyzer_bin
|
||||
chmod +x $rust_analyzer_bin
|
||||
|
||||
echo "rust-analyzer ✓"
|
||||
}
|
||||
|
||||
update_rust_analyzer
|
Reference in New Issue
Block a user