I want to match /foo, but not /foo/ (where foo can be any string) or /
I tried a lot of things along these lines:
sub match :Path :Regex('^[a-z]+$')
sub match :Regex('^[a-z]+$')
sub match :Path :Args(1)
But I cannot achieve what I need.
I don't believe the problem is with my regex, but because I want to handle a path without an argument:
For example, for /aab/c, I get from Catalyst:
[debug] "GET" request for "aab/c" from "192.168.1.100"
[debug] Path is "aab"
[debug] Arguments are "c"