Class: Dependabot::PullRequestCreator::BranchNamer::DependencyGroupStrategy
- Inherits:
-
Base
- Object
- Base
- Dependabot::PullRequestCreator::BranchNamer::DependencyGroupStrategy
- Defined in:
- lib/dependabot/pull_request_creator/branch_namer/dependency_group_strategy.rb
Instance Attribute Summary
Attributes inherited from Base
#dependencies, #files, #max_length, #prefix, #separator, #target_branch
Instance Method Summary collapse
-
#initialize(dependencies:, files:, target_branch:, dependency_group:, separator: "/", prefix: "dependabot", max_length: nil) ⇒ DependencyGroupStrategy
constructor
A new instance of DependencyGroupStrategy.
- #new_branch_name ⇒ Object
Constructor Details
#initialize(dependencies:, files:, target_branch:, dependency_group:, separator: "/", prefix: "dependabot", max_length: nil) ⇒ DependencyGroupStrategy
Returns a new instance of DependencyGroupStrategy.
10 11 12 13 14 15 16 17 18 19 20 21 22 |
# File 'lib/dependabot/pull_request_creator/branch_namer/dependency_group_strategy.rb', line 10 def initialize(dependencies:, files:, target_branch:, dependency_group:, separator: "/", prefix: "dependabot", max_length: nil) super( dependencies: dependencies, files: files, target_branch: target_branch, separator: separator, prefix: prefix, max_length: max_length ) @dependency_group = dependency_group end |
Instance Method Details
#new_branch_name ⇒ Object
24 25 26 |
# File 'lib/dependabot/pull_request_creator/branch_namer/dependency_group_strategy.rb', line 24 def new_branch_name sanitize_branch_name(File.join(prefixes, group_name_with_dependency_digest)) end |