Been trying to make this work, you wont believe how many failed runs i had before now🙂, only to realize i only had to just enable it in my repository settings.
To allow github actions to create pull requests go to https://github.com/USERNAME/REPO_NAME/settings/actions and enable " Allow GitHub Actions to create and approve pull requests"
name: Create PR from dev to main
on:
push: