Sha256: a9ab18f8fd5618590892c42da0066848d3ac3b6fdd0899f5e0ad5f3642778262

Contents?: true

Size: 482 Bytes

Versions: 4

Compression:

Stored size: 482 Bytes

Contents

module GitWrapper
  module Results
    module FileStatus
      STATUSES = {
          'A' => :new_file,
          'M' => :modified,
          'D' => :deleted,
          'R' => :renamed,
          'UU' => :merge_conflict,
          'AA' => :merge_conflict,
          'C' => :copied,
          'T' => :type_changed,
          'X' => :unknown
      }

      def self.value_of(char)
        return :untracked unless STATUSES.key?(char)
        STATUSES[char]
      end
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
git_wrapper-1.1.2 lib/git_wrapper/results/file_status.rb
git_wrapper-1.1.1 lib/git_wrapper/results/file_status.rb
git_wrapper-1.1.0 lib/git_wrapper/results/file_status.rb
git_wrapper-1.0.3 lib/git_wrapper/results/file_status.rb