diff options
author | Stan Hu <stanhu@gmail.com> | 2018-12-06 09:02:11 +0300 |
---|---|---|
committer | Stan Hu <stanhu@gmail.com> | 2018-12-06 10:19:27 +0300 |
commit | e96fd232a628e9f5f008936b5db645412e33cfef (patch) | |
tree | f3694019bc8487f6e212ce16d42a6066fab03977 /app | |
parent | fa3528ee5a0cedf10a05035ce5c713c3fea0ec6f (diff) |
Remove unnecessary includes of ShellAdapter
Determined by running the script:
```
included = `git grep --name-only ShellAdapter`.chomp.split("\n")
used = `git grep --name-only gitlab_shell`.chomp.split("\n")
included - used
```
Diffstat (limited to 'app')
-rw-r--r-- | app/models/concerns/storage/legacy_namespace.rb | 2 | ||||
-rw-r--r-- | app/models/members/project_member.rb | 2 | ||||
-rw-r--r-- | app/models/namespace.rb | 1 | ||||
-rw-r--r-- | app/models/protected_branch.rb | 1 | ||||
-rw-r--r-- | app/models/protected_tag.rb | 1 | ||||
-rw-r--r-- | app/models/repository.rb | 1 | ||||
-rw-r--r-- | app/workers/repository_update_remote_mirror_worker.rb | 1 |
7 files changed, 2 insertions, 7 deletions
diff --git a/app/models/concerns/storage/legacy_namespace.rb b/app/models/concerns/storage/legacy_namespace.rb index af699eeebce..498996f4f80 100644 --- a/app/models/concerns/storage/legacy_namespace.rb +++ b/app/models/concerns/storage/legacy_namespace.rb @@ -4,6 +4,8 @@ module Storage module LegacyNamespace extend ActiveSupport::Concern + include Gitlab::ShellAdapter + def move_dir proj_with_tags = first_project_with_container_registry_tags diff --git a/app/models/members/project_member.rb b/app/models/members/project_member.rb index 537f2a3a231..016c18ce6c8 100644 --- a/app/models/members/project_member.rb +++ b/app/models/members/project_member.rb @@ -3,8 +3,6 @@ class ProjectMember < Member SOURCE_TYPE = 'Project'.freeze - include Gitlab::ShellAdapter - belongs_to :project, foreign_key: 'source_id' # Make sure project member points only to project as it source diff --git a/app/models/namespace.rb b/app/models/namespace.rb index 8865c164b11..3c9b1d32a53 100644 --- a/app/models/namespace.rb +++ b/app/models/namespace.rb @@ -3,7 +3,6 @@ class Namespace < ActiveRecord::Base include CacheMarkdownField include Sortable - include Gitlab::ShellAdapter include Gitlab::VisibilityLevel include Routable include AfterCommitQueue diff --git a/app/models/protected_branch.rb b/app/models/protected_branch.rb index 6c1073265a1..d075440b147 100644 --- a/app/models/protected_branch.rb +++ b/app/models/protected_branch.rb @@ -1,7 +1,6 @@ # frozen_string_literal: true class ProtectedBranch < ActiveRecord::Base - include Gitlab::ShellAdapter include ProtectedRef protected_ref_access_levels :merge, :push diff --git a/app/models/protected_tag.rb b/app/models/protected_tag.rb index 94746141945..d28ebabfe49 100644 --- a/app/models/protected_tag.rb +++ b/app/models/protected_tag.rb @@ -1,7 +1,6 @@ # frozen_string_literal: true class ProtectedTag < ActiveRecord::Base - include Gitlab::ShellAdapter include ProtectedRef validates :name, uniqueness: { scope: :project_id } diff --git a/app/models/repository.rb b/app/models/repository.rb index 35dd120856d..015a179f374 100644 --- a/app/models/repository.rb +++ b/app/models/repository.rb @@ -17,7 +17,6 @@ class Repository #{REF_ENVIRONMENTS} ].freeze - include Gitlab::ShellAdapter include Gitlab::RepositoryCacheAdapter attr_accessor :full_path, :disk_path, :project, :is_wiki diff --git a/app/workers/repository_update_remote_mirror_worker.rb b/app/workers/repository_update_remote_mirror_worker.rb index 9d4e67deb9c..bd429d526bf 100644 --- a/app/workers/repository_update_remote_mirror_worker.rb +++ b/app/workers/repository_update_remote_mirror_worker.rb @@ -5,7 +5,6 @@ class RepositoryUpdateRemoteMirrorWorker UpdateError = Class.new(StandardError) include ApplicationWorker - include Gitlab::ShellAdapter sidekiq_options retry: 3, dead: false |