I'm trying to figure out what's getting passed as the argument when I try to pass a directory as an argument, and I'm getting incredibly strange behavior. For example, from the command line I'm typing:
These are only a few of the files in my home directory. Other directories return nothing at all even though they have hundreds of files in them. How is this behavior explained? I can't make heads or tails of it.
Well, I'm actually trying to fix a ksh and an awk script that somebody else wrote. As I understand it, it's supposed to take every file name in a directory and compare times in the file name to determine which ones to parse. The problem is that it's not picking up file names correctly. Apparently it used to work, but we changed the way we're handling time and now it's broken. The part that's odd looks like the following (this is the ksh):
Right. The tilde was just in my test script. I can put in any directory and I get equally strange results. I tried /tmp and got nothing. I tried the root directory and got 3 files. It seems erratic.