[Ovmsdev] Need some git school
Michael Balzer
dexter at expeedo.de
Wed Mar 17 15:02:54 HKT 2021
Steve,
rebasing creates new commits and discards the original ones. If doing
that on already pushed commits, you normally (always?) need to force the
next push.
I normally only use rebase on my local commits & branches when pulling
in remote updates / preparing to merge them.
Regards,
Michael
Am 16.03.21 um 21:34 schrieb Stephen Casner:
> I haven't gotten any traction on my request for people to test the
> updated mongoose-wolfssl branch, so I thought it might help to rebase
> to the current master. I did that without complaint in my local
> repository, but I can't push that back to github:
>
> auge92> git push
> To github.com:openvehicles/Open-Vehicle-Monitoring-System-3.git
> ! [rejected] mongoose-wolfssl -> mongoose-wolfssl (non-fast-forward)
> error: failed to push some refs to 'github.com:openvehicles/Open-Vehicle-Monitoring-System-3.git'
> hint: Updates were rejected because the tip of your current branch is behind
> hint: its remote counterpart. Integrate the remote changes (e.g.
> hint: 'git pull ...') before pushing again.
> hint: See the 'Note about fast-forwards' in 'git push --help' for details.
>
> I have all the same changes on my local repo as on github, but I
> observe that all the commits I made since branching (beginning with
> 04fafb83a3cc5563a5feb70a4bb7922457d58893) have a different commit id
> than what is in my local mongoose-wolfssl repo for the same changes.
> This is what causes the complaint above.
>
> I must have done something wrong back at the beginning of working on
> this branch. Any idea what I might have done?
>
> Would this be an appropriate scenario to use "git push --force" to
> correct the problem?
>
> -- Steve
> _______________________________________________
> OvmsDev mailing list
> OvmsDev at lists.openvehicles.com
> http://lists.openvehicles.com/mailman/listinfo/ovmsdev
--
Michael Balzer * Helkenberger Weg 9 * D-58256 Ennepetal
Fon 02333 / 833 5735 * Handy 0176 / 206 989 26
-------------- next part --------------
A non-text attachment was scrubbed...
Name: OpenPGP_signature
Type: application/pgp-signature
Size: 203 bytes
Desc: OpenPGP digital signature
URL: <http://lists.openvehicles.com/pipermail/ovmsdev/attachments/20210317/2f247b07/attachment.sig>
More information about the OvmsDev
mailing list