bash 使用しているバージョンを確認する

bash 使用しているバージョンを確認する

使用しているbashのバージョンを確認する手順を記述してます。

環境

  • OS Rocky Linux 8.3

バージョン確認

–versionオプションを使用すれば、確認することが可能です。

bash --version

<出力結果>
GNU bash, バージョン 5.1.4(1)-release (x86_64-pc-linux-gnu)
Copyright (C) 2020 Free Software Foundation, Inc.
ライセンス GPLv3+: GNU GPL バージョン 3 またはそれ以降 <http://gnu.org/licenses/gpl.html>

This is free software; you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

また、現在、使用しているshellは、以下のコマンドで確認することができます。

ls -l  /proc/$$/exe

<出力結果>
lrwxrwxrwx. 1 testuser testuser 0  5月 12 12:28 /proc/323574/exe -> /usr/local/bin/bash