pull-request

How to set up a code review using Gitlab?

家住魔仙堡 提交于 2019-12-03 02:09:57
问题 How does one set up a code review using Gitlab? I see it listed as a feature on the Gitlab website, but I can't seem to find instructions on how to set one up (For that matter, any link to a Gitlab user manual would be most appreciated). Some of my searching has indicated that 'Merge Requests' are the way to go... but I'm finding them limiting. An issued merge request shows all of the commits between one branch and the other. I seem to only be able to view diffs generated for each individual

How to configure Travis-CI to build pull requests & merges to master w/o redundancy

无人久伴 提交于 2019-12-03 01:47:16
问题 To put it in "BDD" terms: Background: Given I'm contributing to a GH repo When I create a pull request Then Travis should build the latest commit When I push to an existing pull request Then Travis should build the latest commit When I merge a pull request to master Then Travis should build master I was confused by Travis-CI's "build pushes" and "build PRs" settings, as: Enabling both causes each Pull Request to be build twice by Travis once for the commit on that branch and once again for

What's the workflow to contribute to an open source project using git pull requests? (eg. via Github)

扶醉桌前 提交于 2019-12-03 00:16:56
问题 I have a comprehensive step by step description on how I do this and I wanted to share it here so developers can benefit from it (I'll answer my own question). 回答1: Since changes contributed to open source projects will have to be peer reviewed it's common to see a workflow which relies on git pull requests. Pull requests are not allowed from directly cloned repos (you need your own fork). So these are the steps I follow to maintain a healthy fork and contribute to an open source periodically

Compare old and new versions of force-pushed GitHub pull request

情到浓时终转凉″ 提交于 2019-12-03 00:06:07
Frequently, my colleagues will make some changes to an open pull request, rebase their local branch against the base branch - often squashing their changes into previous commits as well - and force-push. How can I see what changed between the old version of the PR and the new version of the PR? I guess I could do a git pull and git checkout $BRANCH_NAME when the PR was first raised, then git fetch and then git diff $BRANCH_NAME..origin/$BRANCH_NAME after the PR was updated - but that will also show changes that have been introduced into the base branch (typically master) and brought into the

How do I submit another pull request once the first one was merged?

馋奶兔 提交于 2019-12-02 19:17:19
问题 I forked a public Github repository, cloned the fork to a local repo, made some changes, pushed them to the master branch of my fork. Then I opened a pull request and it was merged into the original repo. Now I want to make next changes. I do them locally, push to the master branch of my fork and try to open another pull request. Github shows both the new changes and the previously merged changes as belonging to this new pull request. Clearly I only want the new changes listed. What am I

Merge in GitHub pull requests, possibly making changes to them first

时间秒杀一切 提交于 2019-12-02 19:00:20
I recently started managing a project on GitHub where people have been submitting pull requests. Rather than merge them to master, I would like the ability to: First vet them to make sure they actually work Possibly making some stylistic changes before merging to master How can I do this? Do you have to make a separate branch, such as "dev", and instruct people to code against that before you merge to master? Jorge Israel Peña There is a github help page on this which details how to make changes to a pull request by checking out pull requests locally. What I might try is first creating a

Set the develop branch as the default for a pull request

送分小仙女□ 提交于 2019-12-02 18:12:18
I want to make the pull request merge into develop from the feature branch by default. I'm advocating the use of git flow, so when a pull request is submitted for a feature, the pull request needs to get merged into develop, and not master. Some of the managers commented that being human, there is a possibility that the team leads could overlook that fact and merge the pull request into master by mistake, causing issues with the release later on. We want to mitigate the risks of merge hell so this would go a long way in achieving this goal. Edit: I'm using a fork of gitflow called hubflow(

Adding commits to another person's pull request on GitHub

一笑奈何 提交于 2019-12-02 17:29:46
My project on GitHub has received a pull request . The pull request only partly fixes the issue that it's addressing. I've pulled in the changes to a local branch and added some commits of my own. I'd now like to push those commits back to my remote repo and have them show up on the pull request, but without merging them into the target branch. I'd like to keep the pull request open for further review and discussion, and potentially further commits. Is there a way I can add commits to the pull request without merging them into the target branch and therefore closing the pull request? As long

Create a GitHub webhook for when a pull request is accepted & merged to master

自作多情 提交于 2019-12-02 17:26:41
I have a webhook that currently fires on push to any branch. This triggers the webhook far too frequently. Ideally, the webhook would only fire when a pull request is merged into master . I don't see that as an option, though: Is there a way to get additional webhook options or to customize the webhook somehow? So, you can't customize the conditions of the trigger, but as LeGec mentions you can customize your code to only trigger when the Pull Request is merged. To do that, make sure your script responds to the PullRequestEvent . The conditions to test are: "action" is " closed " "merged"

github: Adding commits to existing pull request

拥有回忆 提交于 2019-12-02 17:13:42
I opened a pull request to rails repo on github by using Fork & Edit this file file button. Now, After getting feedback on my PR, I wanted to add some more commits. so here is what I ended by doing $ git clone git@github.com:gaurish/rails.git #my forked repo $ git rebase -i 785a2e5 #commit hash of my commit using which PR was opened $ git checkout patch-3 #branch name I had to send my commits under to be shown in that PR $ git commit -am "Changes done as per feedback" $ git push origin patch-3 This worked fine but seems quite a complex workflow. Maybe I am wrong something wrong here? my