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
Tatuya Kamada
gitlab-ce
Commits
e16cebac
Commit
e16cebac
authored
Jan 05, 2013
by
Dmitriy Zaporozhets
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed styles, ProjectHook specs etc
parent
c6298678
Changes
22
Show whitespace changes
Inline
Side-by-side
Showing
22 changed files
with
110 additions
and
75 deletions
+110
-75
app/assets/stylesheets/gitlab_bootstrap/blocks.scss
app/assets/stylesheets/gitlab_bootstrap/blocks.scss
+32
-1
app/assets/stylesheets/gitlab_bootstrap/lists.scss
app/assets/stylesheets/gitlab_bootstrap/lists.scss
+4
-0
app/assets/stylesheets/gitlab_bootstrap/tables.scss
app/assets/stylesheets/gitlab_bootstrap/tables.scss
+1
-1
app/assets/stylesheets/sections/issues.scss
app/assets/stylesheets/sections/issues.scss
+4
-10
app/assets/stylesheets/sections/projects.scss
app/assets/stylesheets/sections/projects.scss
+1
-7
app/models/commit.rb
app/models/commit.rb
+7
-1
app/models/project.rb
app/models/project.rb
+2
-2
app/views/admin/dashboard/index.html.haml
app/views/admin/dashboard/index.html.haml
+4
-4
app/views/admin/projects/show.html.haml
app/views/admin/projects/show.html.haml
+36
-35
app/views/commits/_commits.html.haml
app/views/commits/_commits.html.haml
+1
-1
app/views/dashboard/issues.html.haml
app/views/dashboard/issues.html.haml
+2
-1
app/views/dashboard/merge_requests.html.haml
app/views/dashboard/merge_requests.html.haml
+2
-1
app/views/groups/_projects.html.haml
app/views/groups/_projects.html.haml
+1
-1
app/views/groups/issues.html.haml
app/views/groups/issues.html.haml
+2
-1
app/views/groups/merge_requests.html.haml
app/views/groups/merge_requests.html.haml
+2
-1
app/views/groups/people.html.haml
app/views/groups/people.html.haml
+1
-1
app/views/issues/index.html.haml
app/views/issues/index.html.haml
+1
-1
app/views/merge_requests/show/_commits.html.haml
app/views/merge_requests/show/_commits.html.haml
+1
-1
app/views/team_members/_team.html.haml
app/views/team_members/_team.html.haml
+1
-1
lib/static_model.rb
lib/static_model.rb
+1
-1
spec/lib/extracts_path_spec.rb
spec/lib/extracts_path_spec.rb
+1
-1
spec/models/project_hooks_spec.rb
spec/models/project_hooks_spec.rb
+3
-2
No files found.
app/assets/stylesheets/gitlab_bootstrap/blocks.scss
View file @
e16cebac
...
@@ -79,13 +79,44 @@
...
@@ -79,13 +79,44 @@
}
}
.title
{
.title
{
padding
:
0
10px
;
@include
bg-gray-gradient
;
@include
bg-gray-gradient
;
border-bottom
:
1px
solid
#CCC
;
border-bottom
:
1px
solid
#CCC
;
color
:
#456
;
font-size
:
16px
;
text-shadow
:
0
1px
1px
#fff
;
padding
:
0px
10px
;
line-height
:
36px
;
font-size
:
14px
;
font-weight
:
normal
;
>
a
{
>
a
{
text-shadow
:
0
1px
1px
#fff
;
text-shadow
:
0
1px
1px
#fff
;
}
}
form
{
margin-bottom
:
0
;
margin-top
:
3px
;
}
.nav-pills
{
>
li
{
>
a
{
padding
:
13px
;
margin
:
0
;
font-size
:
13px
;
}
&
.active
{
>
a
{
background
:
#D5D5D5
;
color
:
$style_color
;
@include
border-radius
(
0
);
border-radius
:
0
;
border-left
:
1px
solid
#CCC
;
border-right
:
1px
solid
#CCC
;
}
}
}
}
}
}
&
.padded
{
&
.padded
{
...
...
app/assets/stylesheets/gitlab_bootstrap/lists.scss
View file @
e16cebac
...
@@ -25,6 +25,10 @@
...
@@ -25,6 +25,10 @@
&
:last-child
{
&
:last-child
{
border-bottom
:
none
;
border-bottom
:
none
;
&
.bottom
{
background
:
#f5f5f5
;
}
}
}
.author
{
color
:
#999
;
}
.author
{
color
:
#999
;
}
...
...
app/assets/stylesheets/gitlab_bootstrap/tables.scss
View file @
e16cebac
...
@@ -25,7 +25,7 @@ table {
...
@@ -25,7 +25,7 @@ table {
}
}
th
,
td
{
th
,
td
{
padding
:
8
px
;
padding
:
10
px
;
line-height
:
18px
;
line-height
:
18px
;
text-align
:
left
;
text-align
:
left
;
}
}
...
...
app/assets/stylesheets/sections/issues.scss
View file @
e16cebac
...
@@ -61,31 +61,25 @@ input.check_all_issues {
...
@@ -61,31 +61,25 @@ input.check_all_issues {
#issues-table-holder
{
#issues-table-holder
{
.issues_filters
{
.issues_filters
{
form
{
padding
:
0
;
margin
:
0
;
margin-top
:
7px
}
}
}
.issues_bulk_update
{
.issues_bulk_update
{
margin
:
0
;
margin
:
0
;
form
{
form
{
padding
:
0
;
float
:left
;
margin
:
0
;
margin-top
:
7px
}
}
.update_selected_issues
{
.update_selected_issues
{
position
:
relative
;
position
:
relative
;
top
:
-2
px
;
top
:
5
px
;
margin-left
:
4px
;
margin-left
:
4px
;
float
:
left
;
float
:
left
;
}
}
.update_issues_text
{
.update_issues_text
{
padding
:
3px
;
padding
:
3px
;
line-height
:
1
8px
;
line-height
:
2
8px
;
float
:
left
;
float
:
left
;
color
:
#479
;
}
}
}
}
}
}
...
...
app/assets/stylesheets/sections/projects.scss
View file @
e16cebac
...
@@ -8,14 +8,8 @@
...
@@ -8,14 +8,8 @@
.groups_box
,
.groups_box
,
.projects_box
{
.projects_box
{
>
h5
{
>
.title
{
color
:
#456
;
font-size
:
16px
;
text-shadow
:
0
1px
1px
#fff
;
padding
:
2px
15px
;
padding
:
2px
15px
;
line-height
:
36px
;
font-size
:
14px
;
font-weight
:
normal
;
}
}
.nav-projects-tabs
li
{
padding
:
0
;
}
.nav-projects-tabs
li
{
padding
:
0
;
}
.well-list
{
.well-list
{
...
...
app/models/commit.rb
View file @
e16cebac
...
@@ -98,6 +98,8 @@ class Commit
...
@@ -98,6 +98,8 @@ class Commit
end
end
def
initialize
(
raw_commit
,
head
=
nil
)
def
initialize
(
raw_commit
,
head
=
nil
)
raise
"Nil as raw commit passed"
unless
raw_commit
@commit
=
raw_commit
@commit
=
raw_commit
@head
=
head
@head
=
head
end
end
...
@@ -136,7 +138,11 @@ class Commit
...
@@ -136,7 +138,11 @@ class Commit
end
end
def
prev_commit
def
prev_commit
parents
.
try
:first
@prev_commit
||=
if
parents
.
present?
Commit
.
new
(
parents
.
first
)
else
nil
end
end
end
def
prev_commit_id
def
prev_commit_id
...
...
app/models/project.rb
View file @
e16cebac
...
@@ -361,8 +361,8 @@ class Project < ActiveRecord::Base
...
@@ -361,8 +361,8 @@ class Project < ActiveRecord::Base
# Discover the default branch, but only if it hasn't already been set to
# Discover the default branch, but only if it hasn't already been set to
# something else
# something else
if
default_branch
.
nil?
if
repository
&&
default_branch
.
nil?
update_attributes
(
default_branch:
discover_default_branch
)
update_attributes
(
default_branch:
self
.
repository
.
discover_default_branch
)
end
end
end
end
...
...
app/views/admin/dashboard/index.html.haml
View file @
e16cebac
.admin_dash.row
.admin_dash.row
.span3
.span3
.ui-box
.ui-box
%h5
Projects
%h5
.title
Projects
.data.padded
.data.padded
=
link_to
admin_projects_path
do
=
link_to
admin_projects_path
do
%h1
=
Project
.
count
%h1
=
Project
.
count
...
@@ -9,7 +9,7 @@
...
@@ -9,7 +9,7 @@
=
link_to
'New Project'
,
new_project_path
,
class:
"btn small"
=
link_to
'New Project'
,
new_project_path
,
class:
"btn small"
.span3
.span3
.ui-box
.ui-box
%h5
Groups
%h5
.title
Groups
.data.padded
.data.padded
=
link_to
admin_groups_path
do
=
link_to
admin_groups_path
do
%h1
=
Group
.
count
%h1
=
Group
.
count
...
@@ -17,7 +17,7 @@
...
@@ -17,7 +17,7 @@
=
link_to
'New Group'
,
new_admin_group_path
,
class:
"btn small"
=
link_to
'New Group'
,
new_admin_group_path
,
class:
"btn small"
.span3
.span3
.ui-box
.ui-box
%h5
Users
%h5
.title
Users
.data.padded
.data.padded
=
link_to
admin_users_path
do
=
link_to
admin_users_path
do
%h1
=
User
.
count
%h1
=
User
.
count
...
@@ -25,7 +25,7 @@
...
@@ -25,7 +25,7 @@
=
link_to
'New User'
,
new_admin_user_path
,
class:
"btn small"
=
link_to
'New User'
,
new_admin_user_path
,
class:
"btn small"
.span3
.span3
.ui-box
.ui-box
%h5
%h5
.title
Resque Workers
Resque Workers
.data.padded
.data.padded
-
if
@resque_accessible
-
if
@resque_accessible
...
...
app/views/admin/projects/show.html.haml
View file @
e16cebac
...
@@ -4,7 +4,7 @@
...
@@ -4,7 +4,7 @@
%i
.icon-edit
%i
.icon-edit
Edit
Edit
-
if
@repository
.
has_commits?
-
if
@repository
&&
@repository
.
has_commits?
-
if
!
@repository
.
has_post_receive_file?
-
if
!
@repository
.
has_post_receive_file?
%br
%br
.alert.alert-error
.alert.alert-error
...
@@ -65,18 +65,6 @@
...
@@ -65,18 +65,6 @@
Created at:
Created at:
%td
%td
=
@project
.
created_at
.
stamp
(
"March 1, 1999"
)
=
@project
.
created_at
.
stamp
(
"March 1, 1999"
)
%table
.zebra-striped
%thead
%tr
%th
Repository
%th
%tr
%td
%b
FS Path:
%td
%code
=
@repository
.
path_to_repo
%tr
%tr
%td
%td
%b
%b
...
@@ -89,6 +77,19 @@
...
@@ -89,6 +77,19 @@
SSH:
SSH:
%td
%td
=
link_to
@project
.
ssh_url_to_repo
=
link_to
@project
.
ssh_url_to_repo
-
if
@repository
%table
.zebra-striped
%thead
%tr
%th
Repository
%th
%tr
%td
%b
FS Path:
%td
%code
=
@repository
.
path_to_repo
%tr
%tr
%td
%td
%b
%b
...
...
app/views/commits/_commits.html.haml
View file @
e16cebac
-
@commits
.
group_by
{
|
c
|
c
.
committed_date
.
to_date
}.
each
do
|
day
,
commits
|
-
@commits
.
group_by
{
|
c
|
c
.
committed_date
.
to_date
}.
each
do
|
day
,
commits
|
%div
.ui-box
%div
.ui-box
%h
6
.title
%h
5
.title
%i
.icon-calendar
%i
.icon-calendar
=
day
.
stamp
(
"28 Aug, 2010"
)
=
day
.
stamp
(
"28 Aug, 2010"
)
%ul
.well-list
=
render
commits
%ul
.well-list
=
render
commits
app/views/dashboard/issues.html.haml
View file @
e16cebac
...
@@ -13,7 +13,8 @@
...
@@ -13,7 +13,8 @@
-
@issues
.
group_by
(
&
:project
).
each
do
|
group
|
-
@issues
.
group_by
(
&
:project
).
each
do
|
group
|
%div
.ui-box
%div
.ui-box
-
@project
=
group
[
0
]
-
@project
=
group
[
0
]
%h5
=
link_to_project
@project
%h5
.title
=
link_to_project
@project
%ul
.well-list.issues_table
%ul
.well-list.issues_table
-
group
[
1
].
each
do
|
issue
|
-
group
[
1
].
each
do
|
issue
|
=
render
(
partial:
'issues/show'
,
locals:
{
issue:
issue
})
=
render
(
partial:
'issues/show'
,
locals:
{
issue:
issue
})
...
...
app/views/dashboard/merge_requests.html.haml
View file @
e16cebac
...
@@ -12,7 +12,8 @@
...
@@ -12,7 +12,8 @@
-
@merge_requests
.
group_by
(
&
:project
).
each
do
|
group
|
-
@merge_requests
.
group_by
(
&
:project
).
each
do
|
group
|
.ui-box
.ui-box
-
@project
=
group
[
0
]
-
@project
=
group
[
0
]
%h5
=
link_to_project
@project
%h5
.title
=
link_to_project
@project
%ul
.well-list
%ul
.well-list
-
group
[
1
].
each
do
|
merge_request
|
-
group
[
1
].
each
do
|
merge_request
|
=
render
(
partial:
'merge_requests/merge_request'
,
locals:
{
merge_request:
merge_request
})
=
render
(
partial:
'merge_requests/merge_request'
,
locals:
{
merge_request:
merge_request
})
...
...
app/views/groups/_projects.html.haml
View file @
e16cebac
.projects_box
.projects_box
%h5
%h5
.title
Projects
Projects
%small
%small
(
#{
projects
.
count
}
)
(
#{
projects
.
count
}
)
...
...
app/views/groups/issues.html.haml
View file @
e16cebac
...
@@ -9,7 +9,8 @@
...
@@ -9,7 +9,8 @@
-
@issues
.
group_by
(
&
:project
).
each
do
|
group
|
-
@issues
.
group_by
(
&
:project
).
each
do
|
group
|
%div
.ui-box
%div
.ui-box
-
@project
=
group
[
0
]
-
@project
=
group
[
0
]
%h5
=
@project
.
name
%h5
.title
=
@project
.
name
%ul
.well-list.issues_table
%ul
.well-list.issues_table
-
group
[
1
].
each
do
|
issue
|
-
group
[
1
].
each
do
|
issue
|
=
render
(
partial:
'issues/show'
,
locals:
{
issue:
issue
})
=
render
(
partial:
'issues/show'
,
locals:
{
issue:
issue
})
...
...
app/views/groups/merge_requests.html.haml
View file @
e16cebac
...
@@ -8,7 +8,8 @@
...
@@ -8,7 +8,8 @@
-
@merge_requests
.
group_by
(
&
:project
).
each
do
|
group
|
-
@merge_requests
.
group_by
(
&
:project
).
each
do
|
group
|
%ul
.well-list.ui-box
%ul
.well-list.ui-box
-
@project
=
group
[
0
]
-
@project
=
group
[
0
]
%h5
=
@project
.
name
%h5
.title
=
@project
.
name
-
group
[
1
].
each
do
|
merge_request
|
-
group
[
1
].
each
do
|
merge_request
|
=
render
(
partial:
'merge_requests/merge_request'
,
locals:
{
merge_request:
merge_request
})
=
render
(
partial:
'merge_requests/merge_request'
,
locals:
{
merge_request:
merge_request
})
%hr
%hr
...
...
app/views/groups/people.html.haml
View file @
e16cebac
...
@@ -5,7 +5,7 @@
...
@@ -5,7 +5,7 @@
-
if
can?
(
current_user
,
:manage_group
,
@group
)
-
if
can?
(
current_user
,
:manage_group
,
@group
)
=
render
(
@project
?
"new_member"
:
"new_group_member"
)
=
render
(
@project
?
"new_member"
:
"new_group_member"
)
.ui-box
.ui-box
%h5
%h5
.title
Team
Team
%small
%small
(
#{
@users
.
size
}
)
(
#{
@users
.
size
}
)
...
...
app/views/issues/index.html.haml
View file @
e16cebac
...
@@ -30,7 +30,7 @@
...
@@ -30,7 +30,7 @@
=
select_tag
(
'update[milestone_id]'
,
options_from_collection_for_select
(
issues_active_milestones
,
"id"
,
"title"
,
params
[
:milestone_id
]),
prompt:
"Milestone"
)
=
select_tag
(
'update[milestone_id]'
,
options_from_collection_for_select
(
issues_active_milestones
,
"id"
,
"title"
,
params
[
:milestone_id
]),
prompt:
"Milestone"
)
=
hidden_field_tag
'update[issues_ids]'
,
[]
=
hidden_field_tag
'update[issues_ids]'
,
[]
=
hidden_field_tag
:f
,
params
[
:f
]
=
hidden_field_tag
:f
,
params
[
:f
]
=
button_tag
"Save"
,
class:
"btn update_selected_issues"
=
button_tag
"Save"
,
class:
"btn update_selected_issues
btn-small save-btn
"
.issues_filters
.issues_filters
.left
.left
%ul
.nav.nav-pills.left
%ul
.nav.nav-pills.left
...
...
app/views/merge_requests/show/_commits.html.haml
View file @
e16cebac
-
if
@commits
.
present?
-
if
@commits
.
present?
.ui-box
.ui-box
%h
6
.title
%h
5
.title
%i
.icon-list
%i
.icon-list
Commits (
#{
@commits
.
count
}
)
Commits (
#{
@commits
.
count
}
)
.merge-request-commits
.merge-request-commits
...
...
app/views/team_members/_team.html.haml
View file @
e16cebac
-
grouper_project_members
(
@project
).
each
do
|
access
,
members
|
-
grouper_project_members
(
@project
).
each
do
|
access
,
members
|
.ui-box
.ui-box
%h5
%h5
.title
=
Project
.
access_options
.
key
(
access
).
pluralize
=
Project
.
access_options
.
key
(
access
).
pluralize
%small
=
members
.
size
%small
=
members
.
size
%ul
.well-list
%ul
.well-list
...
...
lib/static_model.rb
View file @
e16cebac
...
@@ -38,7 +38,7 @@ module StaticModel
...
@@ -38,7 +38,7 @@ module StaticModel
end
end
def
==
(
other
)
def
==
(
other
)
if
other
.
is_a?
StaticModel
if
other
.
is_a?
::
StaticModel
id
==
other
.
id
id
==
other
.
id
else
else
super
super
...
...
spec/lib/extracts_path_spec.rb
View file @
e16cebac
...
@@ -7,7 +7,7 @@ describe ExtractsPath do
...
@@ -7,7 +7,7 @@ describe ExtractsPath do
before
do
before
do
@project
=
project
@project
=
project
project
.
stub
(
:ref_names
).
and_return
([
'master'
,
'foo/bar/baz'
,
'v1.0.0'
,
'v2.0.0'
]
)
project
.
stub
(
repository:
stub
(
ref_names:
[
'master'
,
'foo/bar/baz'
,
'v1.0.0'
,
'v2.0.0'
])
)
project
.
stub
(
path_with_namespace:
'gitlab/gitlab-ci'
)
project
.
stub
(
path_with_namespace:
'gitlab/gitlab-ci'
)
end
end
...
...
spec/models/project_hooks_spec.rb
View file @
e16cebac
...
@@ -71,8 +71,9 @@ describe Project, "Hooks" do
...
@@ -71,8 +71,9 @@ describe Project, "Hooks" do
context
"when gathering commit data"
do
context
"when gathering commit data"
do
before
do
before
do
@oldrev
,
@newrev
,
@ref
=
project
.
fresh_commits
(
2
).
last
.
sha
,
project
.
fresh_commits
(
2
).
first
.
sha
,
'refs/heads/master'
@oldrev
,
@newrev
,
@ref
=
project
.
repository
.
fresh_commits
(
2
).
last
.
sha
,
@commit
=
project
.
fresh_commits
(
2
).
first
project
.
repository
.
fresh_commits
(
2
).
first
.
sha
,
'refs/heads/master'
@commit
=
project
.
repository
.
fresh_commits
(
2
).
first
# Fill nil/empty attributes
# Fill nil/empty attributes
project
.
description
=
"This is a description"
project
.
description
=
"This is a description"
...
...
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