gitlab_migration/cli.py
def migrate(src_group, target_group, src_gitlab_url, target_gitlab_url, src_token, target_token):
    '''
    migrate group variables from 1+ groups on one host to a single group on another host
    '''
    if src_group:
        src_group_id = glm._get_namespace_id(src_gitlab_url, src_group, src_token)
    else: 
        src_group_id = None

    target_group_id = glm._get_namespace_id(target_gitlab_url, target_group, target_token)

    for var in glm.get_group_vars(src_gitlab_url, src_token, src_group_id):
        glm.create_group_var(target_gitlab_url, target_token, var, target_group_id)

    migrate group variables from 1+ groups on one host to a single group on another host
    
migrate group variables from 1+ groups on one host to a single group on another host
migrate group variables from 1 + groups on one host to a single group on another host
def migrate(src_group, target_group, src_gitlab_url, target_gitlab_url, src_token, target_token):
    if src_group:
        src_group_id = glm._get_namespace_id(src_gitlab_url, src_group, src_token)
    else: 
        src_group_id = None
    target_group_id = glm._get_namespace_id(target_gitlab_url, target_group, target_token)
    for var in glm.get_group_vars(src_gitlab_url, src_token, src_group_id):
        glm.create_group_var(target_gitlab_url, target_token, var, target_group_id)
def migrate ( src_group , target_group , src_gitlab_url , target_gitlab_url , src_token , target_token ) : if src_group : src_group_id = glm . _get_namespace_id ( src_gitlab_url , src_group , src_token ) else : src_group_id = None target_group_id = glm . _get_namespace_id ( target_gitlab_url , target_group , target_token ) for var in glm . get_group_vars ( src_gitlab_url , src_token , src_group_id ) : glm . create_group_var ( target_gitlab_url , target_token , var , target_group_id )
migrate group variables from 1+ groups on one host to a single group on another host
migrate group variables from 1 + groups on one host to a single group on another host
'''
    migrate group variables from 1+ groups on one host to a single group on another host
    '''
src_group
target_group
src_gitlab_url
target_gitlab_url
src_token
target_token