Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
G
gitlab-mirrors
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
wonko
gitlab-mirrors
Commits
77603d8c
Commit
77603d8c
authored
11 years ago
by
Sam Gleske
Committed by
Git Mirror
11 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Patched critical pagination bug in upstream lib
parent
4bc9cb7c
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
CHANGELOG
+4
-0
4 additions, 0 deletions
CHANGELOG
lib/manage_gitlab_project.py
+7
-3
7 additions, 3 deletions
lib/manage_gitlab_project.py
with
11 additions
and
3 deletions
CHANGELOG
+
4
−
0
View file @
77603d8c
gitlab-mirrors v0.2.5
* Fixed a critical bug with pagination when user can view more projects than 20.
* Had to patch upstream python-gitlab library for this functionality.
gitlab-mirrors v0.2.4
* Fixing critical git svn mirror bug.
...
...
This diff is collapsed.
Click to expand it.
lib/manage_gitlab_project.py
+
7
−
3
View file @
77603d8c
...
...
@@ -52,9 +52,12 @@ def findgroup(gname):
exit
(
1
)
def
findproject
(
gname
,
pname
):
for
project
in
git
.
getProjects
():
if
project
[
'
namespace
'
][
'
name
'
]
==
gname
and
project
[
'
name
'
]
==
pname
:
return
project
page
=
1
while
len
(
git
.
getProjects
(
page
=
page
))
>
0
:
for
project
in
git
.
getProjects
(
page
=
page
):
if
project
[
'
namespace
'
][
'
name
'
]
==
gname
and
project
[
'
name
'
]
==
pname
:
return
project
page
+=
1
else
:
return
False
...
...
@@ -68,6 +71,7 @@ def createproject(pname):
description
=
options
.
desc
new_project
=
git
.
createProject
(
pname
,
description
=
description
,
issues_enabled
=
str
(
int
(
options
.
issues
)),
wall_enabled
=
str
(
int
(
options
.
wall
)),
merge_requests_enabled
=
str
(
int
(
options
.
merge
)),
wiki_enabled
=
str
(
int
(
options
.
wiki
)),
snippets_enabled
=
str
(
int
(
options
.
snippets
)),
public
=
str
(
int
(
options
.
public
)))
new_project
=
findproject
(
gitlab_user
,
pname
)
print
new_project
new_project
=
git
.
moveProject
(
found_group
[
'
id
'
],
new_project
[
'
id
'
])
if
findproject
(
gitlab_namespace
,
pname
):
return
findproject
(
gitlab_namespace
,
pname
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment