Commits rejected, access forbidden

Hi,

Thanks for writing and sharing this template, its really useful.

I've found though that despite creating an access token with write_repository permission and adding a CI/CD variable that is available for all environments, masked, not limited to protected branches and not expand reference variable...

image

I find that the committed changes are rejected as access isn't permitted (see example job where PRE_COMMIT_DEBUG is enabled).

I can't work out why this is happening as whilst I've got protections on main branch to require merge requests these are pushes to a new branch ci-pre-commit-debug. Its like the Access Token isn't providing access.

I'm sure its something I've got wrong but can't figure it out.