2015-10-21 09:15:54 -04:00
|
|
|
# Projects::HousekeepingService class
|
|
|
|
#
|
|
|
|
# Used for git housekeeping
|
|
|
|
#
|
|
|
|
# Ex.
|
2015-11-19 09:16:54 -05:00
|
|
|
# Projects::HousekeepingService.new(project).execute
|
2015-10-21 09:15:54 -04:00
|
|
|
#
|
|
|
|
module Projects
|
|
|
|
class HousekeepingService < BaseService
|
|
|
|
include Gitlab::ShellAdapter
|
|
|
|
|
|
|
|
def initialize(project)
|
|
|
|
@project = project
|
|
|
|
end
|
|
|
|
|
|
|
|
def execute
|
2015-11-19 10:04:07 -05:00
|
|
|
GitlabShellWorker.perform_async(:gc, @project.path_with_namespace)
|
2015-10-21 09:15:54 -04:00
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|