Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
Linux の Firefox ブラウザーを介して行われるすべての通信を監視する C プログラムを作成しました。そのため、Firefox が起動したらすぐにプログラムを実行する必要があります。どうすればよいか教えてください。
bash ラッパー スクリプトを作成する
#!/bin/bash my_c_program firefox
わかりやすい名前を付けて、 に記載されているパスに配置し$PATHます。
$PATH
または、エイリアスに入れることもできます:
alias firefox_starter='my_c_program; firefox'
この行をスタートアップ プログラムに追加します ( .bashrc)
.bashrc