stripping tailing path separator from env name