Thursday, December 17, 2009

Show Contents of File on Path

This bash script will show the contents on any file on the path:
#!/bin/sh

# fmore.sh
#
# Written by Gary S. Weaver

more `which $1`
Put it on the path, name the file fmore, and chmod +x it. Then can use it like:
fmore some_script.sh
and regardless of where it is, it will show you its contents.

No comments: