[ARVADOS] updated: f6aee8a6a829c60015506d89a4e87eb9dc96a07a

Git user git at public.curoverse.com
Tue Mar 8 10:27:05 EST 2016


Summary of changes:
 services/api/app/controllers/arvados/v1/repositories_controller.rb    | 4 ++--
 .../api/test/functional/arvados/v1/repositories_controller_test.rb    | 4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)

       via  f6aee8a6a829c60015506d89a4e87eb9dc96a07a (commit)
       via  e5c99ebf68f31d630f2a35f7e4e79e93143a3607 (commit)
      from  be191fe42348d23708f0c4de8ace619644b18b2d (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.


commit f6aee8a6a829c60015506d89a4e87eb9dc96a07a
Merge: be191fe e5c99eb
Author: Brett Smith <brett at curoverse.com>
Date:   Tue Mar 8 10:27:02 2016 -0500

    Merge branch '8439-gitolite-nonff-perms-wip'
    
    Closes #8439, #8525.


commit e5c99ebf68f31d630f2a35f7e4e79e93143a3607
Author: Brett Smith <brett at curoverse.com>
Date:   Tue Feb 23 11:59:25 2016 -0500

    8439: API server suggests RW+ Gitolite permissions for writers.
    
    This lets users with write permission do non-fast-forward pushes.

diff --git a/services/api/app/controllers/arvados/v1/repositories_controller.rb b/services/api/app/controllers/arvados/v1/repositories_controller.rb
index 4bf9a6a..183ed4d 100644
--- a/services/api/app/controllers/arvados/v1/repositories_controller.rb
+++ b/services/api/app/controllers/arvados/v1/repositories_controller.rb
@@ -91,11 +91,11 @@ class Arvados::V1::RepositoriesController < ApplicationController
     @repo_info.values.each do |repo|
       repo[:user_permissions].each do |user_uuid, user_perms|
         if user_perms['can_manage']
-          user_perms['gitolite_permissions'] = 'RW'
+          user_perms['gitolite_permissions'] = 'RW+'
           user_perms['can_write'] = true
           user_perms['can_read'] = true
         elsif user_perms['can_write']
-          user_perms['gitolite_permissions'] = 'RW'
+          user_perms['gitolite_permissions'] = 'RW+'
           user_perms['can_read'] = true
         elsif user_perms['can_read']
           user_perms['gitolite_permissions'] = 'R'
diff --git a/services/api/test/functional/arvados/v1/repositories_controller_test.rb b/services/api/test/functional/arvados/v1/repositories_controller_test.rb
index 514bb66..241a34e 100644
--- a/services/api/test/functional/arvados/v1/repositories_controller_test.rb
+++ b/services/api/test/functional/arvados/v1/repositories_controller_test.rb
@@ -176,13 +176,13 @@ class Arvados::V1::RepositoriesControllerTest < ActionController::TestCase
         end
         if perms['can_write']
           assert u.can? write: repo['uuid']
-          assert_match /RW/, perms['gitolite_permissions']
+          assert_match /RW\+/, perms['gitolite_permissions']
         else
           refute_match /W/, perms['gitolite_permissions']
         end
         if perms['can_manage']
           assert u.can? manage: repo['uuid']
-          assert_match /RW/, perms['gitolite_permissions']
+          assert_match /RW\+/, perms['gitolite_permissions']
         end
       end
     end

-----------------------------------------------------------------------


hooks/post-receive
-- 




More information about the arvados-commits mailing list