I'm often uncertain, whether a program is a script, or a binary.
And where is it installed?
So I wrote a script, which looks
which command would be used (/usr/bin/foo /usr/local/bin/foo ?)
what kind of file it is (script, elf-binary?)
and if it is a script, it is printed to stdout.
Since I made it (and made some improvements) I'm using it quiete often, so perhaps it's useful for others too:
It's GPL:
Don't miss the final empty lineCode:#/bin/bash # (c) 2003 bashguru Stefan Wagner, Berlin Schöneberg, license: GPL # For a programm: # find where it is (especially if there is more than one): # <which> # what kind of hack is this (elf-binary, bash-script?): # <file> # if it is a script, print it: # <cat> if [[ $# -ne 1 ]]; then echo "Usage: whatmakes.sh THIS" exit fi PROG=$1 LOCATION=$(which $PROG) # not needed, 'file' shows it as well: echo $LOCATION file $LOCATION ART=$(file $LOCATION | grep -c text) if [[ ART -eq 1 ]]; then cat $LOCATION fi
Put it into ~/bin or /usr/local/bin to have it easy accessible in your path.
Feedback is welcome.
manpage and option --help should be made... I know...

RAM Memory Lot 8GB 16GB DDR4 Mixed Speeds Tested & Working
$1470.00
128 GB MICRON (4x32gb) 2RX4 PC4-2933Y DDR4 SERVER MEMORY MTA36ASF4G72PZ-2G9E2
$750.00
2 in 1 USB 3.0 Card Reader Micro TF card Reader usb adapter High Speed Cardreder
$3.99
P43330-0A1 HPE 32GB 2RX8 PC5-4800B DDR5 SERVER RAM P43328-B21 / HMCG88MEBRA107N
$1100.00
Kingston 32GB 64GB 128GB 256GB USB 3.0 Flash Drive Thumb Memory Stick Pen lot
$285.90
USB 3.0 Flash Drive 32GB 64GB 128GB Memory Stick Thumb Stick Lot Pack
$826.09
Samsung 16GB DDR4 ECC Registered PC4-2666V 288-Pin RDIMM RAM M393A2K40CB2
$60.00
Lot of 8 PIECES: Kingston 32GB DDR4-3200MHz KVR32N22D8/32 Desktop Memory Ram
$1299.00
2 Pack USB C SD TF Card Reader Adapter Zinc Alloy USB-C to USB for iPhone 15-17
$3.35
Apple iPad Mini 5 64GB, Wi-Fi, 7.9"
$69.00