Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
Push Options: Control Gitlab CI/CD and Merges with Git Push (docs.gitlab.com)
81 points by CaliforniaKarl on April 13, 2022 | hide | past | favorite | 11 comments


One of the things I miss about phabricator was how much you could do via the CLI (clunky and weird as it was), nice to see something similar in Gitlab but I wish it wasn't so obscure.


I use `git push -o ci.skip` all the time. Also things like ci.variable="DEPLOY_MODE=QUICK" is super handy when I do want to run a deploy in a specific configuration.


An option I would like is for when you push to a repository that doesn't exist, in which case GL creates a new private one for you. I'd like to be able to set it public.


GitLab team member here. I would love that option too...I added https://gitlab.com/gitlab-org/gitlab/-/issues/359270


I love this feature, and use it a lot, but yeowzers it's opaque


GitLab team member here. And I totally agree - I forget to use them all the time!

And thoughts on making it easier? Maybe a suggested set of git aliases or some sort of wrapper?


The docs page linked have git alias suggestions, but perhaps "git push -o gitlab.help"? And that operation would be free to abort the push in the same way that "git commit -h" doesn't actually execute the commit. I'd guess returning like the 5 most common options and then the URL to the help page would be stellar

I lot of my problem is that I don't recall how "-o ci.varables" get merged; I have to say:

> now, is it "-o ci.variables=alpha=beta,charlie=delta" or "-o ci.variables=a=b -o ci.variables=c=d"?

.. and then that syntax gets jumbled up in my head with the "&var[alpha]=beta" syntax from the "/-/pipelines/new" URL so that just makes it worse

And all of this is a fantastic discussion for someone who knows that subsystem exists, but just can't recall offhand the specifics -- but as for how a new user to GitLab would know about such a thing -- maybe at the bottom of the "/-/pipelines/new" page, show the equivalent "git push -o" syntax that would reproduce the pipeline request with its variables?

And maybe the same at the bottom of the "create merge request" page, although that could be super chatty when multiplied by the number of times that create merge request page must be visited

Even if none of this sounds appealing, I do sincerely appreciate you asking. It's this level of customer-focus and strive for improvement that makes me absolutely love GitLab!


I like a lot of these ideas, I added these issues:

- Add squash commits option in push options for merge requests [1]

- Show equivalent push options at bottom of /-/pipelines/new [2]

- Show equivalent push options at bottom of create merge request page [3]

[1]: https://gitlab.com/gitlab-org/gitlab/-/issues/324619

[2]: https://gitlab.com/gitlab-org/gitlab/-/issues/359268

[3]: https://gitlab.com/gitlab-org/gitlab/-/issues/359269

(edited for line spacing)


Spit out tips in the push shell output from time to time, maybe? Not sure if you have guidelines around what can go there but I definitely appreciate the helpful stuff GitLab has added there.


GitLab team member here. I like this option a lot and I added https://gitlab.com/gitlab-org/gitlab/-/issues/359271


When you push, perhaps it could print out the default values as a hint they can be overridden, e.g. ci.skip=false would perhaps indicate to users that this is a setting that can be changed from the push.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: