Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Boxiang Sun
gitlab-ce
Commits
f85712fb
Commit
f85712fb
authored
Jul 12, 2018
by
Stan Hu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use browse URL of project to link imports
parent
fd2c27ac
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
5 deletions
+5
-5
app/views/import/bitbucket_server/status.html.haml
app/views/import/bitbucket_server/status.html.haml
+3
-3
lib/bitbucket_server/representation/repo.rb
lib/bitbucket_server/representation/repo.rb
+1
-1
lib/gitlab/bitbucket_server_import/project_creator.rb
lib/gitlab/bitbucket_server_import/project_creator.rb
+1
-1
No files found.
app/views/import/bitbucket_server/status.html.haml
View file @
f85712fb
...
...
@@ -35,7 +35,7 @@
-
@already_added_projects
.
each
do
|
project
|
%tr
{
id:
"project_#{project.id}"
,
class:
"#{project_status_css_class(project.import_status)}"
}
%td
=
link_to
project
.
import_source
,
"https://bitbucket.org/
#{
project
.
import_source
}
"
,
target:
'_blank'
,
rel:
'noopener noreferrer'
=
link_to
project
.
import_source
,
project
.
import_source
,
target:
'_blank'
,
rel:
'noopener noreferrer'
%td
=
link_to
project
.
full_path
,
[
project
.
namespace
.
becomes
(
Namespace
),
project
]
%td
.job-status
...
...
@@ -73,14 +73,14 @@
-
@incompatible_repos
.
each
do
|
repo
|
%tr
{
id:
"repo_#{repo.owner}___#{repo.slug}"
}
%td
=
link_to
repo
.
full_name
,
"https://bitbucket.org/
#{
repo
.
full_name
}
"
,
target:
'_blank'
,
rel:
'noopener noreferrer'
=
link_to
repo
.
full_name
,
repo
.
browse_url
,
target:
'_blank'
,
rel:
'noopener noreferrer'
%td
.import-target
%td
.import-actions-job-status
=
label_tag
'Incompatible Project'
,
nil
,
class:
'label badge-danger'
-
if
@incompatible_repos
.
any?
%p
One or more of your Bitbucket projects cannot be imported into GitLab
One or more of your Bitbucket
Server
projects cannot be imported into GitLab
directly because they use Subversion or Mercurial for version control,
rather than Git. Please convert
=
link_to
'them to Git,'
,
'https://www.atlassian.com/git/tutorials/migrating-overview'
...
...
lib/bitbucket_server/representation/repo.rb
View file @
f85712fb
...
...
@@ -18,7 +18,7 @@ module BitbucketServer
end
def
browse_url
raw
.
dig
(
'
project'
,
'
links'
,
'self'
).
first
.
fetch
(
'href'
)
raw
.
dig
(
'links'
,
'self'
).
first
.
fetch
(
'href'
)
end
def
clone_url
...
...
lib/gitlab/bitbucket_server_import/project_creator.rb
View file @
f85712fb
...
...
@@ -22,7 +22,7 @@ module Gitlab
namespace_id:
namespace
.
id
,
visibility_level:
repo
.
visibility_level
,
import_type:
'bitbucket_server'
,
import_source:
repo
.
full_name
,
import_source:
repo
.
browse_url
,
import_url:
repo
.
clone_url
,
import_data:
{
credentials:
session_data
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment