0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

メモ wslにubuntuを入れた後の初期設定

Posted at

再インストールを趣味でやるので忘備録

日本語化

日本語言語パックとマニュアルをインストール。

# 日本語言語パックのインストール
sudo apt install -y language-pack-ja

# ロケールを日本語に設定
sudo update-locale LANG=ja_JP.UTF8

# 日本語マニュアルのインストール
sudo apt install -y manpages-ja manpages-ja-dev

エイリアスにエクスプローラを登録

WSL2のターミナルで操作中のディレクトリをexplorerで開く方法はある

explorer.exe .

これで開けるが、単語としてexplorerを覚えるのが難しいので短縮して登録したい。

エイリアスの登録には.bash_aliasesを使う

.bashrcにそう書いてあるし。

# Alias definitions.
# You may want to put all your additions into a separate file like
# ~/.bash_aliases, instead of adding them here directly.
# See /usr/share/doc/bash-doc/examples in the bash-doc package.

.bash_aliasesには

alias ee='explorer.exe'

とでもしておく。これでee .でエクスプローラが開く。

これ自動化できないかな?

しました。

#!/bin/bash
sudo -S apt update && sudo apt upgrade -y && sudo apt install -y language-pack-ja && sudo update-locale LANG=ja_JP.UTF8 && sudo apt install -y manpages-ja manpages-ja-dev
echo alias ee='explorer.exe' > .bash_aliases

やったね。

0
0
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
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?