Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [jakartaee-examples-dev] Git and Pull . . . my hair out and I don't have much left

Hi all, 

I know the sign-off thing usually is something that causes trouble for first-time contributors, me included.
Here is a short video showing how to do this with simple command-line git.

https://youtu.be/YdJyJpT7rrs

Ivar

On Thu, Apr 30, 2020 at 11:47 AM <Hussain.NM@xxxxxxxxxxxxx> wrote:
Sent it quickly, the rebase command to add signed-off is

git rebase -f --signoff HEAD~3

--signoff - this will add the signed-off-by line to your commit message with the configured name and email

In your subsequent commits you can use the -s or --signoff option to add it automatically.

git commit -s -m "commit message"

Thanks
Hussain

From: N M, Hussain (Cognizant) <Hussain.NM@xxxxxxxxxxxxx>
Sent: Thursday, April 30, 2020 03:11 PM
To: jakartaee-examples developer discussions <jakartaee-examples-dev@xxxxxxxxxxx>; omniprof@xxxxxxxxx <omniprof@xxxxxxxxx>
Subject: Re: [jakartaee-examples-dev] Git and Pull . . . my hair out and I don't have much left
 
You can use the below command to rebase your branch and add Signed-off-by and then force push the branch.

git rebase -f HEAD~3
git push "origin" --force-with-lease master

git rebase - allows you or edit, remove, squash your commits
-f - force option since the same commits will be overridden
HEAD~3 - number of commits you wish to rebase, in your case 3 commits


git push "origin" - to push your changes to remote
--force-with-lease - force push known changes
master - branch to push

When you force push changes to a branch for which you have already created a pull request, the updates will be reflected on the pull request. There is no need to create a new pull request.

Thanks
Hussain


From: jakartaee-examples-dev-bounces@xxxxxxxxxxx <jakartaee-examples-dev-bounces@xxxxxxxxxxx> on behalf of Ed Bratt <ed.bratt@xxxxxxxxxx>
Sent: Thursday, April 30, 2020 12:00 PM
To: jakartaee-examples developer discussions <jakartaee-examples-dev@xxxxxxxxxxx>; omniprof@xxxxxxxxx <omniprof@xxxxxxxxx>
Subject: Re: [jakartaee-examples-dev] Git and Pull . . . my hair out and I don't have much left
 

I believe that each commit needs the signed-off-by tag. You would need to retroactively update all the commits in your PR. (I apologize, the recipe for that has eluded me.)

On 4/29/2020 7:07 PM, omniprof@xxxxxxxxx wrote:

First, I used the wrong name and email address in the git config. Forced to edit a file meaninglessly to fix this so I could push.

 

I corrected this but now I was told I did not have a signed-off-by section in my commit. Forced to edit a file meaninglessly to fix this so I could push.

 

Correcting this didn’t give me the all clear message.

 

Closed the pull request and created a new pull request believing everything was in place but now I’m told I have not signed the appropriate documents. I really thought I did.

 

I’m sure its my fault, I just don’t know how many things I have done wrong and if I have enough fingers on one hand to count them.

 

I guess I can start over again with a new fork.

 

I await further instructions before I break something important.

 

 

 

 

 


_______________________________________________
jakartaee-examples-dev mailing list
jakartaee-examples-dev@xxxxxxxxxxx
To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/jakartaee-examples-dev
This e-mail and any files transmitted with it are for the sole use of the intended recipient(s) and may contain confidential and privileged information. If you are not the intended recipient(s), please reply to the sender and destroy all copies of the original message. Any unauthorized review, use, disclosure, dissemination, forwarding, printing or copying of this email, and/or any action taken in reliance on the contents of this e-mail is strictly prohibited and may be unlawful. Where permitted by applicable law, this e-mail and other e-mail communications sent to and from Cognizant e-mail addresses may be monitored.
_______________________________________________
jakartaee-examples-dev mailing list
jakartaee-examples-dev@xxxxxxxxxxx
To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/jakartaee-examples-dev


--

Ivar Grimstad

Jakarta EE Developer Advocate | Eclipse Foundation, Inc.

Community. Code. Collaboration. 

Join us at our virtual event:
EclipseCon 2020 - October 20-22


Back to the top