Sha256: 940539e5e9c175499e8abac6b6e1a3e84880f3d8eb25ffe3514a07c99130cca5

Contents?: true

Size: 543 Bytes

Versions: 4

Compression:

Stored size: 543 Bytes

Contents

#
#   Used for creating a git branch in relation to a pivotal tracker story.
#
# - story_id: the id of the (pivotal tracker) story that you'll be
#   working on
#
# - config_yaml: the yaml with the projects. Each project has an api_token,
#   id, and path.

module PGit
  class StoryBranch
    attr_reader :id

    def initialize(name_parser)
      @name_parser = name_parser
    end

    def start
      `git checkout -b #{name}`
    end

    def name
      @name_parser.name
    end

    def id
      @name_parser.story_id
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
pgit-1.0.0 lib/pgit/story_branch.rb
pgit-0.0.4 lib/pgit/story_branch.rb
pgit-0.0.3 lib/pgit/story_branch.rb
pgit-0.0.2 lib/pgit/story_branch.rb