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?

nnnの設定

0
Posted at

はじめに

nnnは、CUIファイルマネージャです。
ubuntuへのnnnのインストールと、nnnを終了時にカレントディレクトリを最終ディレクトリに変更する設定をします。

インストール

sudo apt update
sudo apt upgrade -y
sudo apt install nnn

設定

.bashrcに以下の設定を追加する。

export NNN_TMPFILE="$HOME/.config/nnn/.lastd"
nn(){
        nnn "$@"
        if [ -f "$NNN_TMPFILE" ]; then
                . "$NNN_TMPFILE"
                rm -f "$NNN_TMPFILE"
        fi
}

追加後、以下のコマンドを実行する。

source ~/.bashrc

実行

以下のコマンドでnnnを起動する。

nn
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?