vp-05-add-vscode.sh 626 B

1234567891011121314151617181920
  1. #!/bin/bash
  2. if (( $EUID != 0 )); then
  3. echo "Eseguire lo script come amministratore"
  4. exit
  5. fi
  6. # scarico chiave GPG e la installo
  7. wget -qO- https://packages.microsoft.com/keys/microsoft.asc | gpg --dearmor > /tmp/packages.microsoft.gpg
  8. install -D -o root -g root -m 644 /etc/packages.microsoft.gpg /etc/apt/keyrings/packages.microsoft.gpg
  9. # aggiungo il repository
  10. echo "deb [arch=amd64,arm64,armhf signed-by=/etc/apt/keyrings/packages.microsoft.gpg] https://packages.microsoft.com/repos/code stable main" > /etc/apt/sources.list.d/vscode.list
  11. # aggiorno apt
  12. apt-get update
  13. # installo vscodium
  14. apt-get install --yes code