Sha256: 8580573db0f2ba76aec07b079709383e4041cc22f28a4292182b6325c9a36308

Contents?: true

Size: 267 Bytes

Versions: 11

Compression:

Stored size: 267 Bytes

Contents

module GitFame
  class FileUnit < Struct.new(:path)
    def extname
      return @_extname if @_extname
      @_extname = ::File.extname(path).sub(/^\./, "")
      @_extname = @_extname.empty? ? "unknown" : @_extname
    end

    def to_s
      path
    end
  end
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
git_fame-2.5.3 lib/git_fame/file.rb
git_fame-2.5.2 lib/git_fame/file.rb
git_fame-2.5.1 lib/git_fame/file.rb
git_fame-2.5.0 lib/git_fame/file.rb
git_fame-2.4.0 lib/git_fame/file.rb
git_fame-2.3.1 lib/git_fame/file.rb
git_fame-2.2.0 lib/git_fame/file.rb
git_fame-2.0.1 lib/git_fame/file.rb
git_fame-2.0.0 lib/git_fame/file.rb
git_fame-1.7.2 lib/git_fame/file.rb
git_fame-1.7.1 lib/git_fame/file.rb