How to watch file count in a directory (Linux/macOS)?

If you want to monitor file count in some directory simply use this:

watch "ls -A | wc -l"

You can also mask specific files using asterisk char:

watch "ls sess* -A | wc -l"

If you get Argument list too long error, please change command syntax to this:

watch "ls -U | grep -c '^sess'"