BigW Consortium Gitlab
Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gitlab-ce
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Forest Godfrey
gitlab-ce
Commits
5ac2c583
Commit
5ac2c583
authored
Nov 15, 2016
by
Annabel Dunstone Gray
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Create separate view for pipeline view with tabs
parent
14400224
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
140 additions
and
52 deletions
+140
-52
_ci_menu.html.haml
app/views/projects/commit/_ci_menu.html.haml
+4
-0
_pipeline.html.haml
app/views/projects/commit/_pipeline.html.haml
+62
-47
builds.html.haml
app/views/projects/commit/builds.html.haml
+9
-0
_show.html.haml
app/views/projects/merge_requests/_show.html.haml
+6
-0
_with_tabs.html.haml
app/views/projects/pipelines/_with_tabs.html.haml
+51
-0
show.html.haml
app/views/projects/pipelines/show.html.haml
+1
-1
23637-title-bar-pipelines.yml
changelogs/unreleased/23637-title-bar-pipelines.yml
+3
-3
pipelines_spec.rb
spec/features/projects/pipelines_spec.rb
+4
-1
No files found.
app/views/projects/commit/_ci_menu.html.haml
View file @
5ac2c583
...
@@ -8,3 +8,7 @@
...
@@ -8,3 +8,7 @@
=
link_to
pipelines_namespace_project_commit_path
(
@project
.
namespace
,
@project
,
@commit
.
id
)
do
=
link_to
pipelines_namespace_project_commit_path
(
@project
.
namespace
,
@project
,
@commit
.
id
)
do
Pipelines
Pipelines
%span
.badge
=
@ci_pipelines
.
count
%span
.badge
=
@ci_pipelines
.
count
=
nav_link
(
path:
'commit#builds'
)
do
=
link_to
builds_namespace_project_commit_path
(
@project
.
namespace
,
@project
,
@commit
.
id
)
do
Builds
%span
.badge
=
@statuses
.
count
app/views/projects/commit/_pipeline.html.haml
View file @
5ac2c583
.tabs-holder
.pipeline-graph-container
%ul
.nav-links.no-top.no-bottom
.row-content-block.build-content.middle-block.pipeline-actions
%li
.active
.pull-right
=
link_to
"Pipeline"
,
"#js-tab-pipeline"
,
data:
{
target:
'#js-tab-pipeline'
,
action:
'pipeline'
,
toggle:
'tab'
}
-
if
can?
(
current_user
,
:update_pipeline
,
pipeline
.
project
)
%li
-
if
pipeline
.
builds
.
latest
.
failed
.
any?
(
&
:retryable?
)
=
link_to
"#js-tab-builds"
,
data:
{
target:
'#js-tab-builds'
,
action:
'build'
,
toggle:
'tab'
}
do
=
link_to
"Retry failed"
,
retry_namespace_project_pipeline_path
(
pipeline
.
project
.
namespace
,
pipeline
.
project
,
pipeline
.
id
),
class:
'btn btn-grouped btn-primary'
,
method: :post
Builds
%span
.badge
=
pipeline
.
statuses
.
count
.tab-content
-
if
pipeline
.
builds
.
running_or_pending
.
any?
#js-tab-pipeline
.tab-pane.active
=
link_to
"Cancel running"
,
cancel_namespace_project_pipeline_path
(
pipeline
.
project
.
namespace
,
pipeline
.
project
,
pipeline
.
id
),
data:
{
confirm:
'Are you sure?'
},
class:
'btn btn-grouped btn-danger'
,
method: :post
.build-content.middle-block.pipeline-graph
.pipeline-visualization
%ul
.stage-column-list
-
stages
=
pipeline
.
stages_with_latest_statuses
-
stages
.
each
do
|
stage
,
statuses
|
%li
.stage-column
.stage-name
%a
{
name:
stage
}
-
if
stage
=
stage
.
titleize
.builds-container
%ul
=
render
"projects/commit/pipeline_stage"
,
statuses:
statuses
#js-tab-builds
.tab-pane
.oneline.clearfix
-
if
pipeline
.
yaml_errors
.
present?
-
if
defined?
(
pipeline_details
)
&&
pipeline_details
.bs-callout.bs-callout-danger
Pipeline
%h4
Found errors in your .gitlab-ci.yml:
=
link_to
"#
#{
pipeline
.
id
}
"
,
namespace_project_pipeline_path
(
pipeline
.
project
.
namespace
,
pipeline
.
project
,
pipeline
.
id
),
class:
"monospace"
%ul
with
-
pipeline
.
yaml_errors
.
split
(
","
).
each
do
|
error
|
=
pluralize
pipeline
.
statuses
.
count
(
:id
),
"build"
%li
=
error
-
if
pipeline
.
ref
You can also test your .gitlab-ci.yml in the
#{
link_to
"Lint"
,
ci_lint_path
}
for
=
link_to
pipeline
.
ref
,
namespace_project_commits_path
(
pipeline
.
project
.
namespace
,
pipeline
.
project
,
pipeline
.
ref
),
class:
"monospace"
-
if
defined?
(
link_to_commit
)
&&
link_to_commit
for commit
=
link_to
pipeline
.
short_sha
,
namespace_project_commit_path
(
pipeline
.
project
.
namespace
,
pipeline
.
project
,
pipeline
.
sha
),
class:
"monospace"
-
if
pipeline
.
duration
in
=
time_interval_in_words
pipeline
.
duration
-
if
pipeline
.
project
.
builds_enabled?
&&
!
pipeline
.
ci_yaml_file
.row-content-block.build-content.middle-block.pipeline-graph.hidden
.bs-callout.bs-callout-warning
.pipeline-visualization
\.gitlab-ci.yml not found in this commit
%ul
.stage-column-list
-
stages
=
pipeline
.
stages_with_latest_statuses
-
stages
.
each
do
|
stage
,
statuses
|
%li
.stage-column
.stage-name
%a
{
name:
stage
}
-
if
stage
=
stage
.
titleize
.builds-container
%ul
=
render
"projects/commit/pipeline_stage"
,
statuses:
statuses
.table-holder.pipeline-holder
%table
.table.ci-table.pipeline
-
if
pipeline
.
yaml_errors
.
present?
%thead
.bs-callout.bs-callout-danger
%tr
%h4
Found errors in your .gitlab-ci.yml:
%th
Status
%ul
%th
Build ID
-
pipeline
.
yaml_errors
.
split
(
","
).
each
do
|
error
|
%th
Name
%li
=
error
%th
You can also test your .gitlab-ci.yml in the
#{
link_to
"Lint"
,
ci_lint_path
}
-
if
pipeline
.
project
.
build_coverage_enabled?
%th
Coverage
-
if
pipeline
.
project
.
builds_enabled?
&&
!
pipeline
.
ci_yaml_file
%th
.bs-callout.bs-callout-warning
-
pipeline
.
statuses
.
relevant
.
stages
.
each
do
|
stage
|
\.gitlab-ci.yml not found in this commit
=
render
'projects/commit/ci_stage'
,
stage:
stage
,
statuses:
pipeline
.
statuses
.
relevant
.
where
(
stage:
stage
)
.table-holder.pipeline-holder
%table
.table.ci-table.pipeline
%thead
%tr
%th
Status
%th
Build ID
%th
Name
%th
-
if
pipeline
.
project
.
build_coverage_enabled?
%th
Coverage
%th
-
pipeline
.
statuses
.
relevant
.
stages
.
each
do
|
stage
|
=
render
'projects/commit/ci_stage'
,
stage:
stage
,
statuses:
pipeline
.
statuses
.
relevant
.
where
(
stage:
stage
)
app/views/projects/commit/builds.html.haml
0 → 100644
View file @
5ac2c583
-
@no_container
=
true
-
page_title
"Builds"
,
"
#{
@commit
.
title
}
(
#{
@commit
.
short_id
}
)"
,
"Commits"
=
render
"projects/commits/head"
%div
{
class:
container_class
}
=
render
"commit_box"
=
render
"ci_menu"
=
render
"builds"
app/views/projects/merge_requests/_show.html.haml
View file @
5ac2c583
...
@@ -64,6 +64,10 @@
...
@@ -64,6 +64,10 @@
=
link_to
pipelines_namespace_project_merge_request_path
(
@project
.
namespace
,
@project
,
@merge_request
),
data:
{
target:
'#pipelines'
,
action:
'pipelines'
,
toggle:
'tab'
}
do
=
link_to
pipelines_namespace_project_merge_request_path
(
@project
.
namespace
,
@project
,
@merge_request
),
data:
{
target:
'#pipelines'
,
action:
'pipelines'
,
toggle:
'tab'
}
do
Pipelines
Pipelines
%span
.badge
=
@pipelines
.
size
%span
.badge
=
@pipelines
.
size
%li
.builds-tab
=
link_to
builds_namespace_project_merge_request_path
(
@project
.
namespace
,
@project
,
@merge_request
),
data:
{
target:
'#builds'
,
action:
'builds'
,
toggle:
'tab'
}
do
Builds
%span
.badge
=
@statuses
.
size
%li
.diffs-tab
%li
.diffs-tab
=
link_to
diffs_namespace_project_merge_request_path
(
@project
.
namespace
,
@project
,
@merge_request
),
data:
{
target:
'div#diffs'
,
action:
'diffs'
,
toggle:
'tab'
}
do
=
link_to
diffs_namespace_project_merge_request_path
(
@project
.
namespace
,
@project
,
@merge_request
),
data:
{
target:
'div#diffs'
,
action:
'diffs'
,
toggle:
'tab'
}
do
Changes
Changes
...
@@ -91,6 +95,8 @@
...
@@ -91,6 +95,8 @@
#commits
.commits.tab-pane
#commits
.commits.tab-pane
-
# This tab is always loaded via AJAX
-
# This tab is always loaded via AJAX
#builds
.builds.tab-pane
-
# This tab is always loaded via AJAX
#pipelines
.pipelines.tab-pane
#pipelines
.pipelines.tab-pane
-
# This tab is always loaded via AJAX
-
# This tab is always loaded via AJAX
#diffs
.diffs.tab-pane
#diffs
.diffs.tab-pane
...
...
app/views/projects/pipelines/_with_tabs.html.haml
0 → 100644
View file @
5ac2c583
.tabs-holder
%ul
.nav-links.no-top.no-bottom
%li
.active
=
link_to
"Pipeline"
,
"#js-tab-pipeline"
,
data:
{
target:
'#js-tab-pipeline'
,
action:
'pipeline'
,
toggle:
'tab'
}
%li
=
link_to
"#js-tab-builds"
,
data:
{
target:
'#js-tab-builds'
,
action:
'build'
,
toggle:
'tab'
}
do
Builds
%span
.badge
=
pipeline
.
statuses
.
count
.tab-content
#js-tab-pipeline
.tab-pane.active
.build-content.middle-block.pipeline-graph
.pipeline-visualization
%ul
.stage-column-list
-
stages
=
pipeline
.
stages_with_latest_statuses
-
stages
.
each
do
|
stage
,
statuses
|
%li
.stage-column
.stage-name
%a
{
name:
stage
}
-
if
stage
=
stage
.
titleize
.builds-container
%ul
=
render
"projects/commit/pipeline_stage"
,
statuses:
statuses
#js-tab-builds
.tab-pane
-
if
pipeline
.
yaml_errors
.
present?
.bs-callout.bs-callout-danger
%h4
Found errors in your .gitlab-ci.yml:
%ul
-
pipeline
.
yaml_errors
.
split
(
","
).
each
do
|
error
|
%li
=
error
You can also test your .gitlab-ci.yml in the
#{
link_to
"Lint"
,
ci_lint_path
}
-
if
pipeline
.
project
.
builds_enabled?
&&
!
pipeline
.
ci_yaml_file
.bs-callout.bs-callout-warning
\.gitlab-ci.yml not found in this commit
.table-holder.pipeline-holder
%table
.table.ci-table.pipeline
%thead
%tr
%th
Status
%th
Build ID
%th
Name
%th
-
if
pipeline
.
project
.
build_coverage_enabled?
%th
Coverage
%th
-
pipeline
.
statuses
.
relevant
.
stages
.
each
do
|
stage
|
=
render
'projects/commit/ci_stage'
,
stage:
stage
,
statuses:
pipeline
.
statuses
.
relevant
.
where
(
stage:
stage
)
app/views/projects/pipelines/show.html.haml
View file @
5ac2c583
...
@@ -6,4 +6,4 @@
...
@@ -6,4 +6,4 @@
-
if
@commit
-
if
@commit
=
render
"projects/pipelines/info"
=
render
"projects/pipelines/info"
=
render
"projects/
commit/pipeline
"
,
pipeline:
@pipeline
=
render
"projects/
pipelines/with_tabs
"
,
pipeline:
@pipeline
changelogs/unreleased/23637-title-bar-pipelines.yml
View file @
5ac2c583
---
---
title
:
23637-title-bar-pipelines
title
:
Redesign pipelines page
merge_request
:
merge_request
:
author
:
author
:
spec/features/projects/pipelines_spec.rb
View file @
5ac2c583
...
@@ -156,7 +156,10 @@ describe "Pipelines" do
...
@@ -156,7 +156,10 @@ describe "Pipelines" do
@external
=
create
(
:generic_commit_status
,
status:
'success'
,
pipeline:
pipeline
,
name:
'jenkins'
,
stage:
'external'
)
@external
=
create
(
:generic_commit_status
,
status:
'success'
,
pipeline:
pipeline
,
name:
'jenkins'
,
stage:
'external'
)
end
end
before
{
visit
namespace_project_pipeline_path
(
project
.
namespace
,
project
,
pipeline
)
}
before
do
visit
namespace_project_pipeline_path
(
project
.
namespace
,
project
,
pipeline
)
find
(
'.builds-tab'
).
click
end
it
'shows a list of builds'
do
it
'shows a list of builds'
do
expect
(
page
).
to
have_content
(
'Test'
)
expect
(
page
).
to
have_content
(
'Test'
)
...
...
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