はじめに
Linuxには実用性とは別に、エンターテイメント性の高いコマンドが数多く存在する。
今回紹介するhollywood
コマンドもその一つで、「fill your console with Hollywood melodrama technobabble
」というキャッチフレーズの通り、ターミナルをハリウッド映画のハッカーシーンのように演出してくれるネタコマンドである。
このコマンドは、複数のターミナルツールを組み合わせて、映画でよく見るような「何かすごいことをしているように見える」画面を作り出してくれる。
プレゼンテーションや友人への驚かしネタ、または単純に楽しむために使えるコマンドである。
環境
WSL2 Ubuntu 24.04 LTS
インストール方法
Ubuntu/Debianの場合
# パッケージリストを更新
sudo apt update
# hollywoodコマンドのインストール
sudo apt install hollywood
ログ
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following packages were automatically installed and are no longer required:
crack-common libdouble-conversion3 libgl1-amber-dri libglapi-mesa libllvm17t64 libmd4c0 libpcre2-16-0 libqt5core5t64 libqt5dbus5t64
libqt5gui5t64 libqt5network5t64 libqt5qml5 libqt5qmlmodels5 libqt5quick5 libqt5svg5 libqt5waylandclient5 libqt5waylandcompositor5
libqt5widgets5t64 libqt5x11extras5 libxcb-damage0 libxcb-xinerama0 libxcb-xinput0 mesa-utils-bin qt5-gtk-platformtheme qttranslations5-l10n
qtwayland5 xbitmaps
Use 'sudo apt autoremove' to remove them.
The following additional packages will be installed:
bmon ccze cmatrix htop jp2a libconfuse-common libconfuse2 libio-pty-perl libipc-run-perl libtime-duration-perl liburing2 moreutils plocate
python3-urwid python3-wcwidth speedometer
Suggested packages:
cmatrix-xfont strace python-urwid-doc
The following NEW packages will be installed:
bmon ccze cmatrix hollywood htop jp2a libconfuse-common libconfuse2 libio-pty-perl libipc-run-perl libtime-duration-perl liburing2 moreutils
plocate python3-urwid python3-wcwidth speedometer
0 upgraded, 17 newly installed, 0 to remove and 69 not upgraded.
Need to get 3234 kB of archives.
After this operation, 6860 kB of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 http://archive.ubuntu.com/ubuntu noble/universe amd64 libconfuse-common all 3.3-3build1 [5894 B]
Get:2 http://archive.ubuntu.com/ubuntu noble/universe amd64 libconfuse2 amd64 3.3-3build1 [26.8 kB]
Get:3 http://archive.ubuntu.com/ubuntu noble/universe amd64 bmon amd64 1:4.0-10 [47.0 kB]
Get:4 http://archive.ubuntu.com/ubuntu noble/universe amd64 cmatrix amd64 2.0-6 [33.7 kB]
Get:5 http://archive.ubuntu.com/ubuntu noble/universe amd64 hollywood all 1.21-1.1 [2263 kB]
Get:6 http://archive.ubuntu.com/ubuntu noble/main amd64 htop amd64 3.3.0-4build1 [171 kB]
Get:7 http://archive.ubuntu.com/ubuntu noble/universe amd64 jp2a amd64 1.1.1-2ubuntu2 [28.6 kB]
Get:8 http://archive.ubuntu.com/ubuntu noble/main amd64 libio-pty-perl amd64 1:1.20-1build2 [31.2 kB]
Get:9 http://archive.ubuntu.com/ubuntu noble/main amd64 libipc-run-perl all 20231003.0-1 [92.1 kB]
Get:10 http://archive.ubuntu.com/ubuntu noble/main amd64 libtime-duration-perl all 1.21-2 [12.3 kB]
Get:11 http://archive.ubuntu.com/ubuntu noble/main amd64 liburing2 amd64 2.5-1build1 [21.1 kB]
Get:12 http://archive.ubuntu.com/ubuntu noble/universe amd64 moreutils amd64 0.69-1 [56.4 kB]
Get:13 http://archive.ubuntu.com/ubuntu noble/universe amd64 plocate amd64 1.1.19-2ubuntu2 [139 kB]
Get:14 http://archive.ubuntu.com/ubuntu noble/main amd64 python3-wcwidth all 0.2.5+dfsg1-1.1ubuntu1 [22.5 kB]
Get:15 http://archive.ubuntu.com/ubuntu noble/main amd64 python3-urwid amd64 2.6.10-1 [183 kB]
Get:16 http://archive.ubuntu.com/ubuntu noble/universe amd64 speedometer all 2.9-0.1 [16.1 kB]
Get:17 http://archive.ubuntu.com/ubuntu noble/universe amd64 ccze amd64 0.2.1-8 [84.7 kB]
Fetched 3234 kB in 5s (594 kB/s)
Selecting previously unselected package libconfuse-common.
(Reading database ... 127629 files and directories currently installed.)
Preparing to unpack .../00-libconfuse-common_3.3-3build1_all.deb ...
Unpacking libconfuse-common (3.3-3build1) ...
Selecting previously unselected package libconfuse2:amd64.
Preparing to unpack .../01-libconfuse2_3.3-3build1_amd64.deb ...
Unpacking libconfuse2:amd64 (3.3-3build1) ...
Selecting previously unselected package bmon.
Preparing to unpack .../02-bmon_1%3a4.0-10_amd64.deb ...
Unpacking bmon (1:4.0-10) ...
Selecting previously unselected package cmatrix.
Preparing to unpack .../03-cmatrix_2.0-6_amd64.deb ...
Unpacking cmatrix (2.0-6) ...
Selecting previously unselected package hollywood.
Preparing to unpack .../04-hollywood_1.21-1.1_all.deb ...
Unpacking hollywood (1.21-1.1) ...
Selecting previously unselected package htop.
Preparing to unpack .../05-htop_3.3.0-4build1_amd64.deb ...
Unpacking htop (3.3.0-4build1) ...
Selecting previously unselected package jp2a.
Preparing to unpack .../06-jp2a_1.1.1-2ubuntu2_amd64.deb ...
Unpacking jp2a (1.1.1-2ubuntu2) ...
Selecting previously unselected package libio-pty-perl.
Preparing to unpack .../07-libio-pty-perl_1%3a1.20-1build2_amd64.deb ...
Unpacking libio-pty-perl (1:1.20-1build2) ...
Selecting previously unselected package libipc-run-perl.
Preparing to unpack .../08-libipc-run-perl_20231003.0-1_all.deb ...
Unpacking libipc-run-perl (20231003.0-1) ...
Selecting previously unselected package libtime-duration-perl.
Preparing to unpack .../09-libtime-duration-perl_1.21-2_all.deb ...
Unpacking libtime-duration-perl (1.21-2) ...
Selecting previously unselected package liburing2:amd64.
Preparing to unpack .../10-liburing2_2.5-1build1_amd64.deb ...
Unpacking liburing2:amd64 (2.5-1build1) ...
Selecting previously unselected package moreutils.
Preparing to unpack .../11-moreutils_0.69-1_amd64.deb ...
Unpacking moreutils (0.69-1) ...
Selecting previously unselected package plocate.
Preparing to unpack .../12-plocate_1.1.19-2ubuntu2_amd64.deb ...
Unpacking plocate (1.1.19-2ubuntu2) ...
Selecting previously unselected package python3-wcwidth.
Preparing to unpack .../13-python3-wcwidth_0.2.5+dfsg1-1.1ubuntu1_all.deb ...
Unpacking python3-wcwidth (0.2.5+dfsg1-1.1ubuntu1) ...
Selecting previously unselected package python3-urwid.
Preparing to unpack .../14-python3-urwid_2.6.10-1_amd64.deb ...
Unpacking python3-urwid (2.6.10-1) ...
Selecting previously unselected package speedometer.
Preparing to unpack .../15-speedometer_2.9-0.1_all.deb ...
Unpacking speedometer (2.9-0.1) ...
Selecting previously unselected package ccze.
Preparing to unpack .../16-ccze_0.2.1-8_amd64.deb ...
Unpacking ccze (0.2.1-8) ...
Setting up libio-pty-perl (1:1.20-1build2) ...
Setting up htop (3.3.0-4build1) ...
Setting up jp2a (1.1.1-2ubuntu2) ...
Setting up cmatrix (2.0-6) ...
Setting up python3-wcwidth (0.2.5+dfsg1-1.1ubuntu1) ...
Setting up hollywood (1.21-1.1) ...
Setting up libipc-run-perl (20231003.0-1) ...
Setting up libtime-duration-perl (1.21-2) ...
Setting up libconfuse-common (3.3-3build1) ...
Setting up liburing2:amd64 (2.5-1build1) ...
Setting up libconfuse2:amd64 (3.3-3build1) ...
Setting up ccze (0.2.1-8) ...
Setting up moreutils (0.69-1) ...
Setting up python3-urwid (2.6.10-1) ...
Setting up speedometer (2.9-0.1) ...
Setting up bmon (1:4.0-10) ...
Setting up plocate (1.1.19-2ubuntu2) ...
update-alternatives: using /usr/bin/plocate to provide /usr/bin/locate (locate) in auto mode
info: Selecting GID from range 100 to 999 ...
info: Adding group `plocate' (GID 121) ...
Initializing plocate database; this may take some time... done
Created symlink /etc/systemd/system/timers.target.wants/plocate-updatedb.timer → /usr/lib/systemd/system/plocate-updatedb.timer.
Processing triggers for hicolor-icon-theme (0.17-2) ...
Processing triggers for gnome-menus (3.36.0-1.1ubuntu3) ...
Processing triggers for libc-bin (2.39-0ubuntu8.4) ...
Processing triggers for man-db (2.12.0-4build2) ...
Processing triggers for desktop-file-utils (0.27-2build1) ...
その他のディストリビューションの場合
hollywoodは主にUbuntu/Debian系で提供されているが、他のディストリビューションでも以下の方法でインストール可能となっている
# Snapパッケージ経由でのインストール
sudo snap install hollywood
# または、GitHubからソースコードを取得
git clone https://github.com/dustinkirkland/hollywood.git
cd hollywood
sudo make install
基本的な使い方
実行
# hollywoodコマンドを実行
hollywood
コマンドを実行すると、ターミナルが分割され、以下のような要素が表示される
- システムプロセスの監視画面
- ネットワークトラフィックの表示
- ログファイルの流し読み
- Matrixのような文字の流れ
- システム情報の表示
- その他、ハッカーっぽい表示
終了方法
# Ctrl+Cで終了
# または
# qキーで終了(画面によって異なる)
実際に使ってみる
初回起動時の様子
$ hollywood
コマンドを実行すると、即座にターミナルが複数のペインに分割されて画面が表示される。
使用されているツール群
hollywoodが内部で使用しているツールを確認してみる
# hollywoodの実行中に使用されているプロセスを確認
ps aux | grep hollywood
~ ps aux | grep hollywood ✔ │ 21:50:09
kbushi 46828 0.0 0.0 2804 1060 pts/31 SNs+ 21:50 0:00 /bin/sh /usr/bin/../lib/hollywood/htop
kbushi 49708 0.0 0.0 2984 2164 pts/20 SNs+ 21:50 0:00 /bin/sh /usr/bin/../lib/hollywood/stat
kbushi 49737 0.0 0.0 2804 2124 pts/24 SNs+ 21:50 0:00 /bin/sh /usr/bin/../lib/hollywood/man
kbushi 49757 0.0 0.0 2804 1116 pts/25 SNs+ 21:50 0:00 /bin/sh /usr/bin/../lib/hollywood/map
kbushi 49774 0.0 0.0 2804 2072 pts/26 SNs+ 21:50 0:00 /bin/sh /usr/bin/../lib/hollywood/sshart
kbushi 49810 0.0 0.0 2804 1840 pts/27 SNs+ 21:50 0:00 /bin/sh /usr/bin/../lib/hollywood/apg
kbushi 49854 0.0 0.0 2804 1092 pts/28 SNs+ 21:50 0:00 /bin/sh /usr/bin/../lib/hollywood/logs
kbushi 49879 0.0 0.0 2804 1096 pts/29 SNs+ 21:50 0:00 /bin/sh /usr/bin/../lib/hollywood/tree
kbushi 49902 0.0 0.0 2804 1836 pts/30 SNs+ 21:50 0:00 /bin/sh /usr/bin/../lib/hollywood/errno
kbushi 49951 0.3 0.0 2804 1132 pts/32 SNs+ 21:50 0:00 /bin/sh /usr/bin/../lib/hollywood/atop
kbushi 49989 0.1 0.0 4884 3544 pts/34 SNs+ 21:50 0:00 /bin/bash /usr/bin/../lib/hollywood/jp2a
kbushi 50047 0.3 0.0 4756 3420 pts/35 SNs+ 21:50 0:00 /bin/bash /usr/bin/../lib/hollywood/code
kbushi 50271 0.0 0.0 2804 1196 pts/36 SNs+ 21:50 0:00 /bin/sh /usr/bin/../lib/hollywood/speedometer
kbushi 50325 0.0 0.0 2804 1084 pts/33 SNs+ 21:50 0:00 /bin/sh /usr/bin/../lib/hollywood/cmatrix
kbushi 50455 0.0 0.0 2804 1084 pts/37 SNs+ 21:51 0:00 /bin/sh /usr/bin/../lib/hollywood/htop
kbushi 50516 0.0 0.0 2804 2100 pts/38 SNs+ 21:51 0:00 /bin/sh /usr/bin/../lib/hollywood/hexdump
kbushi 53220 0.0 0.0 2787232 25324 pts/40 Sl 21:51 0:00 q _ inline-shell-completion --buffer ps aux | grep hollywood
kbushi 53268 0.0 0.0 4756 1952 pts/35 SN+ 21:51 0:00 /bin/bash /usr/bin/../lib/hollywood/code
kbushi 53274 0.0 0.0 4096 2012 pts/40 S+ 21:51 0:00 grep --color=auto --exclude-dir=.bzr --exclude-dir=CVS --exclude-dir=.git --exclude-dir=.hg --exclude-dir=.svn --exclude-dir=.idea --exclude-dir=.tox --exclude-dir=.venv --exclude-dir=venv hollywood
kbushi 95678 0.0 0.0 9276 5148 pts/19 S+ 21:46 0:00 tmux -u -2 -f /usr/share/byobu/profiles/tmuxrc attach-session -t hollywood
kbushi 95740 13.5 0.4 153448 148564 ? Ss 21:46 0:37 tmux -u -2 -f /usr/share/byobu/profiles/tmuxrc new-session -d -s hollywood /bin/bash
kbushi 96017 0.1 0.0 4888 3620 pts/23 S+ 21:46 0:00 /bin/bash /usr/bin/hollywood
以下のツールが組み合わされていることが分かった
スクリプト名 | 使用ソフトウェア | 機能・役割 |
---|---|---|
htop | htop | システムプロセスをリアルタイム監視 |
cmatrix | cmatrix | Matrix風のアニメーション表示 |
stat | stat | ファイル/ディレクトリの統計情報表示 |
man | man | マニュアルページの表示 |
map | 内蔵スクリプト | システムマップやネットワーク情報表示 |
sshart | 内蔵スクリプト | SSH接続のアスキーアート表示 |
apg | apg | 自動パスワード生成 |
logs | tail/cat | システムログファイルの流し読み |
tree | tree | ディレクトリ構造をツリー表示 |
errno | 内蔵スクリプト | エラーコードとメッセージの表示 |
atop | atop | 高度なシステム監視 |
jp2a | jp2a | 画像をASCIIアートに変換 |
code | 内蔵スクリプト | コード風のテキスト生成 |
speedometer | speedometer | ネットワーク速度をグラフィック表示 |
hexdump | hexdump | バイナリデータの16進数表示 |
これらのツールはtmux
(ターミナルマルチプレクサ)を使用して画面分割され、同時に動作している。
ps
で実行されているコマンドを調べたが、以下に実行されているコマンド軍があることがわかった。
関連コマンドの紹介
hollywoodと組み合わせて楽しめる類似のネタコマンドを紹介する
1. cmatrix
# Matrix風の文字表示
sudo apt install cmatrix
cmatrix
以下の記事で紹介している。
2. sl (Steam Locomotive)
# lsコマンドをミスタイプした時に機関車が走る
sudo apt install sl
sl
3. cowsay
# 牛が喋る
sudo apt install cowsay
echo "Hello World" | cowsay
4. figlet
# ASCII文字でバナーを作成
sudo apt install figlet
figlet "Hollywood"
5. lolcat
# 文字に虹色効果を付ける
sudo apt install lolcat
echo "Rainbow text" | lolcat
参考
Hollywood パッケージ(Ubuntu)
https://packages.ubuntu.com/noble/hollywoodHollywood 公式サイト
https://hollywood.computer/GitHub - dustinkirkland/hollywood
https://github.com/dustinkirkland/hollywood
おわりに
hollywood
コマンドは実用性こそないものの、Linuxの楽しさとターミナルの奥深さを感じさせてくれる素晴らしいネタコマンドだった。
いわゆる、俺やってる感が出るので一旦この画面出しておけばやってる感を演出できるだろう。
技術的なプレゼンテーションでの演出効果や、Linux入門者への興味喚起、または単純に楽しむためのツールとして有効と思う。
また、このコマンドを通じてhtop
、cmatrix
、bmon
などの実用的なツールの存在を知ることができ、それらを個別に学習するきっかけにもなる。Linux
にはこのような遊び心のあるツールが数多く存在するため、時には息抜きとして楽しんでみるのもよい。
ただし、リソース消費量が多いため、当然だが本番環境での使用は避け、あくまでデモやエンターテイメント目的での使用に留めることにする。