Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
李少辉-开发者
gitlab-foss
提交
e322bdbd
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,发现更多精彩内容 >>
提交
e322bdbd
编写于
1月 27, 2014
作者:
D
Dmitriy Zaporozhets
浏览文件
操作
浏览文件
下载
差异文件
Merge branch 'fix/test' of /mnt/ebs/repositories/jhworth.developer/gitlab-ce
上级
3713fc6c
39a2adf4
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
5 addition
and
9 deletion
+5
-9
app/mailers/notify.rb
app/mailers/notify.rb
+1
-1
config/initializers/1_settings.rb
config/initializers/1_settings.rb
+3
-7
spec/models/project_spec.rb
spec/models/project_spec.rb
+1
-1
未找到文件。
app/mailers/notify.rb
浏览文件 @
e322bdbd
...
...
@@ -12,7 +12,7 @@ class Notify < ActionMailer::Base
default_url_options
[
:host
]
=
Gitlab
.
config
.
gitlab
.
host
default_url_options
[
:protocol
]
=
Gitlab
.
config
.
gitlab
.
protocol
default_url_options
[
:port
]
=
Gitlab
.
config
.
gitlab
.
port
if
Gitlab
.
config
.
gitlab_on_n
on_standard_port?
default_url_options
[
:port
]
=
Gitlab
.
config
.
gitlab
.
port
unless
Gitlab
.
config
.
gitlab_
on_standard_port?
default_url_options
[
:script_name
]
=
Gitlab
.
config
.
gitlab
.
relative_url_root
default
from:
Gitlab
.
config
.
gitlab
.
email_from
...
...
config/initializers/1_settings.rb
浏览文件 @
e322bdbd
...
...
@@ -3,8 +3,8 @@ class Settings < Settingslogic
namespace
Rails
.
env
class
<<
self
def
gitlab_on_
non_
standard_port?
!
[
443
,
80
].
include?
(
gitlab
.
port
.
to_i
)
def
gitlab_on_standard_port?
gitlab
.
port
.
to_i
==
(
gitlab
.
https
?
443
:
80
)
end
private
...
...
@@ -18,11 +18,7 @@ class Settings < Settingslogic
end
def
build_gitlab_url
if
gitlab_on_non_standard_port?
custom_port
=
":
#{
gitlab
.
port
}
"
else
custom_port
=
nil
end
custom_port
=
gitlab_on_standard_port?
?
nil
:
":
#{
gitlab
.
port
}
"
[
gitlab
.
protocol
,
"://"
,
gitlab
.
host
,
...
...
spec/models/project_spec.rb
浏览文件 @
e322bdbd
...
...
@@ -101,7 +101,7 @@ describe Project do
it
"returns the web URL without the protocol for this repo"
do
project
=
Project
.
new
(
path:
"somewhere"
)
project
.
web_url_without_protocol
.
should
==
"
#{
Gitlab
.
config
.
gitlab
.
host
}
/somewhere"
project
.
web_url_without_protocol
.
should
==
"
#{
Gitlab
.
config
.
gitlab
.
url
.
split
(
"://"
)[
1
]
}
/somewhere"
end
describe
"last_activity methods"
do
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录