Go to file
2019-08-16 14:14:21 +07:00
config First commit 2019-04-11 23:39:59 +02:00
lib Wrong function name 2019-04-23 13:05:28 +02:00
native/xler_native Close #3 Added dirty cpu flag for method parse, worksheets 2019-08-16 14:14:21 +07:00
test First commit 2019-04-11 23:39:59 +02:00
.formatter.exs First commit 2019-04-11 23:39:59 +02:00
.gitignore Add xls files to ignore 2019-06-28 00:14:14 +02:00
.tool-versions Up the version 2019-06-28 00:12:19 +02:00
LICENSE Add LICENSE 2019-04-11 21:43:27 +00:00
mix.exs Merge branch 'master' of gitlab.com:jnylen/xler 2019-06-28 00:13:04 +02:00
mix.lock Up the version 2019-06-28 00:12:19 +02:00
README.md Up version 2019-04-23 09:21:00 +02:00

Xler

Xler uses the Calamine Rust library to get contents of Excel files.

Calamine supports:

  • excel (xls, xlsx, xlsm, xlsb, xla, xlam)
  • opendocument spreadsheets (ods)

Installation

If available in Hex, the package can be installed by adding xler to your list of dependencies in mix.exs:

def deps do
  [
    {:xler, "~> 0.2.0"}
  ]
end

Documentation can be generated with ExDoc and published on HexDocs. Once published, the docs can be found at https://hexdocs.pm/xler.

Worksheets

To get the worksheets of a file you use:

Xler.worksheets("filename.xls")

and it will return as a tuple:

{:ok, ["Sheet 1"]}

Parse

To get the data of a worksheet you use:

Xler.parse("filename.xls", "Sheet 1")

and it will return as a tuple:

{:ok, [["Date", "Time"]]}