Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support providing custom branch name for build:env:push #420

Open
G-Rath opened this issue Nov 24, 2021 · 2 comments
Open

Support providing custom branch name for build:env:push #420

G-Rath opened this issue Nov 24, 2021 · 2 comments

Comments

@G-Rath
Copy link

G-Rath commented Nov 24, 2021

Currently build:env:push is hard-coded to use the master branch if it's not a multi-dev call:

$branch = ($multidev == 'dev') ? 'master' : $multidev;

We've both moved to using main for our branches instead of master, and actually want to have a specific deployment branch that CI commits to so that devs don't have to do asset compiling themselves (e.g. we ignore our compiled assets, and then CI builds + forcefully commits them to the deployment branch, which is then deployed from).

I would say long-term it would probably make sense to make a global --default-branch config value that gets used in these situations.

@greg-1-anderson
Copy link
Member

Right now, the build tools plugin assumes that the GitHub (/ GitLab / Bitbucket) branch always matches the Pantheon branch. The Pantheon branch for the dev environment must be "master". We've gotten a lot of requests to change this, but it's hardcoded in too many places to be changed easily, so it will be a while before this can be changed on the platform.

Build tools could, however, be modified to push from the default branch on GitHub (et. al.) to the master branch on Pantheon. This was discussed once; I don't recall what the challenges were.

@G-Rath
Copy link
Author

G-Rath commented Nov 25, 2021

Build tools could, however, be modified to push from the default branch on GitHub (et. al.) to the master branch on Pantheon.

Yeah that's what I had in mind - we're not fussed with what branch pantheon uses in the remote.

(tbh after doing more toying with this, I suspect I'm actually after a build:env:push-commit commit, but that can be another issue)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants