Sha256: ef1b1e2b1e0efde904f4dce995464d8fe3b7e2f47439e33e46b6ce71b8999f1d

Contents?: true

Size: 304 Bytes

Versions: 1

Compression:

Stored size: 304 Bytes

Contents

module DeployNotes
  # Class for local deployments
  class Local
    def get
      "[#{branch_name}] - [#{commit_info}]"
    end

    private

    def branch_name
      `git rev-parse --abbrev-ref HEAD`
    end

    def commit_info
      `git log -n1 --pretty=format:[%ae:%s][%cr][%h]`
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
deploy_notes-0.1.2 lib/deploy_notes/local.rb