2021-01-11 07:54:33 +00:00
|
|
|
|
{ lib, stdenv, fetchzip, jre, makeWrapper }:
|
2018-10-26 14:21:26 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2019-08-15 13:41:18 +01:00
|
|
|
|
pname = "tabula";
|
2018-10-26 14:21:26 +01:00
|
|
|
|
version = "1.2.1";
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
src = fetchzip {
|
|
|
|
|
url = "https://github.com/tabulapdf/tabula/releases/download/v${version}/tabula-jar-${version}.zip";
|
|
|
|
|
sha256 = "0lkpv8hkji81fanyxm7ph8421fr9a6phqc3pbhw2bc4gljg7sgxi";
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
2021-02-07 09:17:39 +00:00
|
|
|
|
nativeBuildInputs = [ makeWrapper ];
|
2018-10-26 14:21:26 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
|
mkdir -pv $out/share/tabula
|
|
|
|
|
cp -v * $out/share/tabula
|
|
|
|
|
|
|
|
|
|
makeWrapper ${jre}/bin/java $out/bin/tabula --add-flags "-jar $out/share/tabula/tabula.jar"
|
|
|
|
|
'';
|
|
|
|
|
|
|
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
|
meta = with lib; {
|
2018-10-26 14:21:26 +01:00
|
|
|
|
description = "A tool for liberating data tables locked inside PDF files";
|
|
|
|
|
longDescription = ''
|
|
|
|
|
If you’ve ever tried to do anything with data provided to you in PDFs, you
|
|
|
|
|
know how painful it is — there's no easy way to copy-and-paste rows of data
|
|
|
|
|
out of PDF files. Tabula allows you to extract that data into a CSV or
|
|
|
|
|
Microsoft Excel spreadsheet using a simple, easy-to-use interface.
|
|
|
|
|
'';
|
2020-04-01 02:11:51 +01:00
|
|
|
|
homepage = "https://tabula.technology/";
|
2018-10-26 14:21:26 +01:00
|
|
|
|
license = licenses.mit;
|
|
|
|
|
maintainers = [ maintainers.dpaetzel ];
|
|
|
|
|
platforms = platforms.all;
|
|
|
|
|
};
|
|
|
|
|
}
|