Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
李少辉-开发者
gitlab-foss
提交
4df4b381
G
gitlab-foss
项目概览
李少辉-开发者
/
gitlab-foss
通知
15
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
G
gitlab-foss
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
提交
4df4b381
编写于
12月 12, 2011
作者:
D
Dmitriy Zaporozhets
浏览文件
操作
浏览文件
下载
差异文件
Merge branch 'master' of github.com:gitlabhq/gitlabhq
上级
5bc97fbd
7b7549be
变更
5
隐藏空白更改
内联
并排
Showing
5 changed file
with
33 addition
and
16 deletion
+33
-16
app/assets/stylesheets/projects.css.scss
app/assets/stylesheets/projects.css.scss
+23
-12
app/helpers/application_helper.rb
app/helpers/application_helper.rb
+1
-0
app/helpers/commits_helper.rb
app/helpers/commits_helper.rb
+0
-2
app/views/refs/_tree.html.haml
app/views/refs/_tree.html.haml
+7
-1
lib/utils.rb
lib/utils.rb
+2
-1
未找到文件。
app/assets/stylesheets/projects.css.scss
浏览文件 @
4df4b381
...
...
@@ -67,8 +67,8 @@ a {
}
}
.view_file
.view_file_header
,
.diff_file
.diff_file_header
{
.view_file
.view_file_header
,
.diff_file
.diff_file_header
{
background-image
:
-webkit-gradient
(
linear
,
0
0
,
0
26
,
color-stop
(
0
.076
,
#fefefe
)
,
to
(
#F6F7F8
));
background-image
:
-webkit-linear-gradient
(
#fefefe
7
.6%
,
#F6F7F8
);
background-image
:
-moz-linear-gradient
(
#fefefe
7
.6%
,
#F6F7F8
);
...
...
@@ -116,7 +116,7 @@ td.code {
word-wrap
:normal
;
}
table
.highlighttable
{
table
.highlighttable
{
border
:
none
;
background
:
#F7F7F7
;
}
...
...
@@ -331,7 +331,7 @@ body.project-page table .commit {
border
:none
;
text-shadow
:none
;
&
.inline
{
&
.inline
{
display
:inline
;
}
...
...
@@ -430,28 +430,28 @@ body.projects-page input.text.git-url.project_list_url { width:165px; }
body
.project-page
table
.no-borders
tr
,
body
.project-page
table
.no-borders
td
{
body
.project-page
table
.no-borders
td
{
border
:none
;
}
#gitlab-tabs
{
#gitlab-tabs
{
.ui-tabs-nav
{
border-bottom
:
1px
solid
#DEDFE1
;
li
{
li
{
background
:
none
;
border
:none
;
font-size
:
16px
;
margin
:
0
;
padding
:
0
;
a
{
a
{
margin
:
0
;
padding
:
10px
16px
;
width
:
150px
;
}
&
.ui-tabs-selected
{
&
.ui-tabs-selected
{
background-image
:
-webkit-gradient
(
linear
,
0
0
,
0
26
,
color-stop
(
0
.076
,
#fefefe
)
,
to
(
#F6F7F8
));
background-image
:
-webkit-linear-gradient
(
#fefefe
7
.6%
,
#F6F7F8
);
background-image
:
-moz-linear-gradient
(
#fefefe
7
.6%
,
#F6F7F8
);
...
...
@@ -466,17 +466,28 @@ body.project-page table.no-borders td{
border-top-left-radius
:
5px
;
border-top-right-radius
:
5px
;
}
}
}
}
}
}
.ajax-tab-loading
{
.ajax-tab-loading
{
padding
:
40px
;
display
:none
;
}
#tree-content-holder
{
float
:left
;
width
:
100%
;
}
#tree-readme-holder
{
float
:left
;
width
:
100%
;
.readme
{
@include
round-borders-all
(
4px
);
padding
:
4px
15px
;
background
:
#F7F7F7
;
}
}
/* Commit Page */
...
...
app/helpers/application_helper.rb
浏览文件 @
4df4b381
require
'digest/md5'
module
ApplicationHelper
include
Utils
::
CharEncode
def
gravatar_icon
(
user_email
)
gravatar_host
=
request
.
ssl?
?
"https://secure.gravatar.com"
:
"http://www.gravatar.com"
...
...
app/helpers/commits_helper.rb
浏览文件 @
4df4b381
module
CommitsHelper
include
Utils
::
CharEncode
def
old_line_number
(
line
,
i
)
end
...
...
app/views/refs/_tree.html.haml
浏览文件 @
4df4b381
...
...
@@ -21,7 +21,7 @@
%th
Last commit
=
link_to
"history"
,
tree
.
history_path
,
:class
=>
"right"
-
if
tree
.
up_dir?
%tr
{
:class
=>
"tree-item"
,
:url
=>
tree
.
up_dir_path
}
%td
.tree-item-file-name
...
...
@@ -35,6 +35,12 @@
-
contents
.
select
{
|
i
|
i
.
is_a?
(
Grit
::
Blob
)}.
each
do
|
content
|
=
render
:partial
=>
"refs/tree_item"
,
:locals
=>
{
:content
=>
content
}
-
if
content
=
contents
.
select
{
|
c
|
c
.
is_a?
(
Grit
::
Blob
)
and
c
.
name
=~
/^readme\.(md|markdown)$/i
}.
first
#tree-readme-holder
%h3
=
content
.
name
.readme
=
markdown
(
encode
content
.
data
)
:javascript
$
(
function
(){
$
(
'
select#branch
'
).
selectmenu
({
style
:
'
popup
'
,
width
:
200
});
...
...
lib/utils.rb
浏览文件 @
4df4b381
...
...
@@ -18,13 +18,14 @@ module Utils
module
CharEncode
def
encode
(
string
)
return
''
unless
string
cd
=
CharDet
.
detect
(
string
)
if
cd
.
confidence
>
0.6
string
.
force_encoding
(
cd
.
encoding
)
end
string
.
encode
(
"utf-8"
,
:undef
=>
:replace
,
:replace
=>
"?"
,
:invalid
=>
:replace
)
rescue
"Invalid
code e
ncoding"
"Invalid
E
ncoding"
end
end
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录