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
1
Merge Requests
1
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
nexedi
gitlab-ce
Commits
5e05669a
Commit
5e05669a
authored
Feb 05, 2018
by
Rémy Coutable
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Make Flay inspect ee/ as well and ignore db files
Signed-off-by:
Rémy Coutable
<
remy@rymai.me
>
parent
b9edd4e8
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
12 additions
and
30 deletions
+12
-30
.flayignore
.flayignore
+4
-0
ee/lib/ee/api/helpers.rb
ee/lib/ee/api/helpers.rb
+3
-0
ee/lib/ee/api/helpers/runner.rb
ee/lib/ee/api/helpers/runner.rb
+4
-0
ee/lib/ee/ci/api/helpers.rb
ee/lib/ee/ci/api/helpers.rb
+0
-29
lib/tasks/flay.rake
lib/tasks/flay.rake
+1
-1
No files found.
.flayignore
View file @
5e05669a
...
...
@@ -15,3 +15,7 @@ app/models/project_services/packagist_service.rb
lib/gitlab/background_migration/normalize_ldap_extern_uids_range.rb
lib/gitlab/background_migration/*
app/models/project_services/kubernetes_service.rb
ee/db/**/*
ee/app/serializers/ee/merge_request_widget_entity.rb
ee/lib/ee/gitlab/ldap/sync/admin_users.rb
ee/lib/ee/api/helpers.rb
View file @
5e05669a
module
EE
module
API
module
Helpers
extend
::
Gitlab
::
Utils
::
Override
override
:current_user
def
current_user
strong_memoize
(
:current_user
)
do
user
=
super
...
...
ee/lib/ee/api/helpers/runner.rb
View file @
5e05669a
...
...
@@ -2,6 +2,9 @@ module EE
module
API
module
Helpers
module
Runner
extend
::
Gitlab
::
Utils
::
Override
override
:authenticate_job!
def
authenticate_job!
id
=
params
[
:id
]
...
...
@@ -13,6 +16,7 @@ module EE
super
end
override
:current_runner
def
current_runner
token
=
params
[
:token
]
...
...
ee/lib/ee/ci/api/helpers.rb
deleted
100644 → 0
View file @
b9edd4e8
module
EE
module
Ci
module
API
module
Helpers
def
authenticate_build!
id
=
params
[
:id
]
if
id
::
Gitlab
::
Database
::
LoadBalancing
::
RackMiddleware
.
stick_or_unstick
(
env
,
:build
,
id
)
end
super
end
def
current_runner
token
=
params
[
:token
]
if
token
::
Gitlab
::
Database
::
LoadBalancing
::
RackMiddleware
.
stick_or_unstick
(
env
,
:runner
,
token
)
end
super
end
end
end
end
end
lib/tasks/flay.rake
View file @
5e05669a
desc
'Code duplication analyze via flay'
task
:flay
do
output
=
`bundle exec flay --mass 35 app/ lib/gitlab/ 2>
#{
File
::
NULL
}
`
output
=
`bundle exec flay --mass 35 app/ lib/gitlab/
ee/
2>
#{
File
::
NULL
}
`
if
output
.
include?
(
"Similar code found"
)
||
output
.
include?
(
"IDENTICAL code found"
)
puts
output
...
...
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