2
7

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

Ubuntu 20.04 での Visual Studio Code のインストール (自動更新対応)

Last updated at Posted at 2020-10-03

Ubuntu 20.04 での Visual Studio Code のインストール (自動更新対応)

https://code.visualstudio.com/docs/setup/linux#_debian-and-ubuntu-based-distributions の手順を shell script にしたものが以下です。
これにより、Visual studio code をインストールします。(確認済み)
もしVisual studio code に更新があれば apt update & apt upgrade で更新できる(はず)。(未確認)

#!/bin/sh

# https://code.visualstudio.com/docs/setup/linux
wget -qO- https://packages.microsoft.com/keys/microsoft.asc | gpg --dearmor > packages.microsoft.gpg
sudo install -o root -g root -m 644 packages.microsoft.gpg /etc/apt/trusted.gpg.d/
sudo sh -c 'echo "deb [arch=amd64 signed-by=/etc/apt/trusted.gpg.d/packages.microsoft.gpg] https://packages.microsoft.com/repos/vscode stable main" > /etc/apt/sources.list.d/vscode.list'

sudo apt-get install apt-transport-https
sudo apt-get update
sudo apt-get install code # or code-insiders

参考
https://code.visualstudio.com/docs/setup/linux#_debian-and-ubuntu-based-distributions

2
7
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
7

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?