[#3][m]: only show current directory - fixes #3 (thx to @alzadude).

* Also minor refactor to move out templating to a separate function.
* Taken from this patch - https://github.com/nineworthies/s3-bucket-listing/commit/38fa104cccecfee4c6796cc5e2262f8cc5d60681