-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Ostree remotes and rebasing #5599
Conversation
Still a WIP because the design requires rebasing to be implemented in order for this to make sense to merge. Also needs tests. @andreasn putting this up now so you can review while I'm working on rebasing. I had to change the add form a little bit. I added the name field and removed the gpg data field. There was a issue with the design if the add succeed but the import failed, so I figured it was ok to make that part of the edit step only. But if you have a different way you like to see it done we can talk about it. Also since rebasing pretty much has to be done in order for this to make it in, figuring out how we want to handle branches would be nice. If we think we can do it without redesigning this dialog then I don't mind making that a follow up. But we are going to include it somehow on this dialog then I'd rather get it in now. |
f1ec493
to
b781f96
Compare
e27140d
to
18c49d5
Compare
Added branches and rebasing with tests. |
4746ef9
to
db59a12
Compare
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.
Wow that's a lot of work. Major.
We need some step by step instructions on how to test this. For the release notes we'll need to record a video, and someone will need to duplicate this.
} | ||
]) | ||
|
||
.directive('modalGroup', [ |
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.
What does modalGroup do. Perhaps a multiline comment here would be helpful describing this directive.
@@ -161,18 +166,49 @@ | |||
phantom_checkpoint(); | |||
}); | |||
|
|||
$scope.knownVersions = function(os) { | |||
return client.known_versions_for(os); | |||
$scope.switchOS = function(os) { |
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.
This function is named as if it switches the operating system in OSTree. More likely it should be named displayOS
or similar, since it only changes the display.
branches.list = data; | ||
}, function (ex) { | ||
branches.error = cockpit.message(ex); | ||
|
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.
Extra line?
.then(function (data) { | ||
branches.list = data; | ||
}, function (ex) { | ||
branches.error = cockpit.message(ex); |
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.
Is it intentional that the branches.list
remains at the old value in this case?
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.
Since branches is created as a new object and only assigned to the scope after the promise is complete. branches.list
will always be undefined in the error case.
* along with Cockpit; If not, see <http://www.gnu.org/licenses/>. | ||
*/ | ||
|
||
(function() { |
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.
New files don't need to use a private block. webpack puts every file in its own block.
*/ | ||
|
||
(function() { | ||
"use strict"; |
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.
New files don't need to use "use strict"
. Webpack builds all the files as strict.
*/ | ||
|
||
(function() { | ||
"use strict"; |
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.
No need for private block or use strict
in new files.
var configRegex = { | ||
section: /^\s*\[\s*([^\]]*)\s*\]\s*$/, | ||
param: /^\s*([\w\.\-\_]+)\s*=\s*(.*?)\s*$/, | ||
lines: /\r\n|\r|\n/ |
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.
These should have comments describing what they match.
Allows us to use the dialog promise and error functionality without having to close the dialog on completion.
db59a12
to
b0bbf11
Compare
<ul class="dropdown-menu"> | ||
<li ng-repeat="name in os_list" | ||
ng-class="{ checked: os == name }"> | ||
<a ng-click="switchOS(name)" value="{{name}}">{{name}}</a> |
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.
This needs to go back to displayOS
Support rebasing to a different remote and branch.
b0bbf11
to
82a8b8e
Compare
82a8b8e
to
e8e2c4e
Compare
Updates done, easiest way to test is to use vm run with an atomic image. Use scp to put the new package in /home/admin/.local/share/cockpit. The online repos have several branches that can be used for testing. |
This looks good to merge. But there's the following follow ups that need fixing:
|
Support rebasing to a different remote and branch. Closes #5599 Reviewed-by: Stef Walter <stefw@redhat.com>
Closes #5599 Reviewed-by: Stef Walter <stefw@redhat.com>
This looks good to merge. But there's the following follow ups that need
fixing:
* " Upgrade target revision
'8b15e9b988b4b02f4cb8b39bdd63d182ab7004a8926ecdac6314ee5c7ffa646b'
with timestamp 'Mon Jan 9 00:43:10 2017' is chronologically older
than current revision
'c2340338ffd4a0d8822e79927efed910e21d900db46c01a68b178a4284844ea3'
with timestamp 'Tue Jan 10 08:27:16 2017'; use --allow-downgrade to
permit "
rpm-ostreed upstream bug, fix is in and will work it's way down to all
the versions eventually. Effects rebasing to older commits
* Should use the listing pattern, as with the credentials dialog.
This would probably need a redesign from @andreasn, I think he was going
for keeping it similar to the tuned dialog.
|
@garrett said he's happy to redesign the listing pattern. |
No description provided.