atom 370 B

12345678910111213
  1. #!/bin/bash
  2. set -o errexit -o pipefail
  3. if [[ "$OS" = "Darwin" ]]; then
  4. [[ -d "$HOME/Applications/Atom.app" ]] || brew cask install atom
  5. defaults write com.github.atom ApplePressAndHoldEnabled -bool false
  6. else
  7. if ! has atom; then
  8. TMP_FILE="/tmp/atom$$.deb"
  9. curl -fSL https://atom.io/download/deb -o "$TMP_FILE"
  10. sudo dpkg -i "$TMP_FILE"
  11. rm "$TMP_FILE"
  12. fi
  13. fi