Sha256: 18d5f2c1c2c42db81c74e8f4c17b0eee4eb43a26af3eee1a7772e06ec66763c9

Contents?: true

Size: 303 Bytes

Versions: 8

Compression:

Stored size: 303 Bytes

Contents

module XCRes
  module FileHelper

    # Return the basename without its extname
    # e.g: 'dir/test.jpg' => 'test'
    #
    # @param  [String] file_path
    #
    # @return [String]
    #
    def basename_without_ext file_path
      File.basename file_path, File.extname(file_path)
    end

  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
xcres-0.6.1 lib/xcres/helper/file_helper.rb
xcres-0.6.0 lib/xcres/helper/file_helper.rb
xcres-0.5.0 lib/xcres/helper/file_helper.rb
xcres-0.4.4 lib/xcres/helper/file_helper.rb
xcres-0.4.3 lib/xcres/helper/file_helper.rb
xcres-0.4.2 lib/xcres/helper/file_helper.rb
xcres-0.4.1 lib/xcres/helper/file_helper.rb
xcres-0.4.0 lib/xcres/helper/file_helper.rb