- #!/bin/bash
 
- set -o errexit -o pipefail
 
- if [[ "$OS" = "Darwin" ]]; then
 
- 	gimme_pkg visual-studio-code
 
- else
 
- 	if ! has code; then
 
- 		URL="https://go.microsoft.com/fwlink/?LinkID=760868"
 
- 		TMP_FILE="/tmp/gimme.vscode-amd64.1.0.0.deb"
 
- 		curl -fSLC- "$URL" -o "$TMP_FILE"
 
- 		sudo dpkg -i "$TMP_FILE"
 
- 		rm "$TMP_FILE"
 
- 	fi
 
- fi
 
 
  |