Status: Closed (View Workflow)
Environment:Microsoft Windows 10 Professional 64-bit
Google Chrome Version 56.0.2924.87 (64-bit)
Sprint:Blue Ocean 1.0-rc3
It looks like github is treating the default branch (nominally master) specially - and this is causing the "save as branch" to only work properly off the master branch.
If you try to save from a non default branch, it will just save the content from the master branch to the new branch, and incorreclty report it as a duplicate when trying to save the changed content.
When editing a Declarative Pipeline Jenkinsfile on the master branch, and adding it to a new branch from the editor, everything works great. But if you edit the Jenkinsfile in the branch created in the editor, and try to create a new branch from there, the branch gets created before the changes to the Jenkinsfile are saved.
Steps to recreate:
1. Make a change to your Jenkinsfile using the editor, and save it to a new branch. Here's a screenshot of this step already completed, where the branch I created is called "CreateANewBranchForNoReason"
2. Provide a description of the change, and a new branch name.
3. Click "Save & run." Notice that you get an error back, saying the branch already exists:
4. Flip over to GitHub itself, and look at your repository. The branch has been created:
5. The only way to dismiss the popup is to click Cancel.
6. Also note that the "Updated" information shown in GitHub is way wrong, by 5 hours. It's reporting 5 hours ago, when I actually ran through these steps about 10 minutes ago: