Return the last path component of path and optionally strip the suffix suffix. This is similar to the well know shell command "basename".