Last active
August 26, 2020 04:23
-
-
Save orlea/d38434203a8eb8872ef309f85feec6bb to your computer and use it in GitHub Desktop.
いい感じにWSL2のubuntuをセットアップするスクリプト
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
set -eu | |
# Update | |
sudo perl -p -i.bak -e 's%https?://(?!security)[^ \t]+%http://jp.archive.ubuntu.com/ubuntu/%g' /etc/apt/sources.list | |
sudo apt update | |
sudo apt upgrade -y | |
# Package install | |
sudo apt install -y zsh tmux vim git gcc make | |
# dotfiles | |
# include input method environment variable | |
curl https://raw.githubusercontent.com/orlea/dotfiles/master/install.sh | sh | |
# font | |
sudo apt install -y fonts-noto-cjk fonts-noto-color-emoji | |
# x11 | |
sudo service dbus start | |
sudo apt install -y xfce4 xfce4-terminal | |
# x11 environment variable | |
cat << EOF >> ~/.profile | |
export DISPLAY=$(cat /etc/resolv.conf | grep nameserver | awk '{print $2}'):0.0 | |
EOF | |
cat << EOF >> ~/.zprofile | |
export DISPLAY=$(cat /etc/resolv.conf | grep nameserver | awk '{print $2}'):0.0 | |
EOF | |
# IM | |
sudo apt install -y fcitx fcitx-mozc | |
# IM-conf | |
source ~/.profile | |
fcitx-autostart | |
fcitx-config-gtk3 | |
# Install golang | |
wget https://golang.org/dl/go1.15.linux-amd64.tar.gz | |
sudo tar -C /usr/local -xzf go1.15.linux-amd64.tar.gz | |
# chsh | |
sudo chsh -s /bin/zsh $USER | |
# set locale | |
sudo apt install -y language-pack-ja language-pack-ja-base | |
sudo update-locale LANG=ja_JP.UTF8 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment