スクリプトの内容を標準出力にダンプ

スクリプトの内容を標準出力にダンプ

bashハッシュの$ PATHに何かがある場合、そのスクリプトの内容をダンプする方法はありますか?

たとえば、これを行うと:

$ type ores_git_push

私は得る:

ores_git_push is hashed (/usr/local/bin/ores_git_push)

スクリプトの内容を取得する方法はありますか?

私がするなら:

$ type -a ores_git_push

私は得る:

ores_git_push is /Users/oleg/.nvm/versions/node/v10.10.0/bin/ores_git_push
ores_git_push is /usr/local/bin/ores_git_push

それで最悪のシナリオでは結果を分析してみることができると思いましたtype -a

ベストアンサー1

cat "$(type -p ores_git_push)"

おすすめ記事