-
Notifications
You must be signed in to change notification settings - Fork 276
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
Force update when local branch is ahead #849
Conversation
Is there a reason to have it only for master and develop? |
@ratoaq2 if someone is using a testing branch or working on another branch and haven't pushed yet, he will lose the commits if this force updated it not only for develop|master |
Valid scenario. But there's another valid one:
The local dev environment should never reset and force update, but the 'production' installation should. |
9e9f3d3
to
47eddaf
Compare
@ratoaq2 can you test please? |
newest_text = "Local branch is ahead of " + self.branch + ". Automatic update not possible." | ||
|
||
elif self._num_commits_behind > 0: | ||
if self._num_commits_behind > 0 or (sickbeard.GIT_RESET and sickbeard.BRANCH in sickbeard.GIT_RESET_BRANCHES): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If there's no branches in the list, it should accept as well
or (sickbeard.GIT_RESET and (not sickbeard.GIT_RESET_BRANCHES or sickbeard.BRANCH in sickbeard.GIT_RESET_BRANCHES))
The same logic some lines below (probably a function would fit: def should_reset)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ratoaq2 Did you try the Ui? Use must select branches in a pre-populated select
Coverage decreased (-0.001%) to 28.88% when pulling d4ea5af9171746e78121850eb79e20af260d0c97 on fix_update into 73678cd on develop. |
Coverage decreased (-0.001%) to 28.88% when pulling d4ea5af9171746e78121850eb79e20af260d0c97 on fix_update into 73678cd on develop. |
Coverage decreased (-0.001%) to 28.88% when pulling 136531050014412618012e23ea8549bd09a9cb07 on fix_update into 73678cd on develop. |
Coverage decreased (-0.008%) to 28.873% when pulling 5998b82aa05442c0f397a60c4851b0c2b4086c83 on fix_update into 73678cd on develop. |
Coverage decreased (-0.008%) to 28.873% when pulling a11b790be9df04a074203b6fc024d6c32322622f on fix_update into 73678cd on develop. |
…update restart loop when local branch is ahead but reset is not allowed. Allow to define an empty 'reset branch list' which means 'any branch' could be reset
Like 'ALLOWED_EXTENSIONS' and other settings
@pymedusa/developers
we recently had to remove one commit from develop which caused a "Local branch is ahead of develop. Automatic update not possible" to develop users
this will affect only develop and master branches.