mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-13 09:13:17 +00:00
f41df75d8a
Signed-off-by: Florian Brandes <florian.brandes@posteo.de>
64 lines
1.3 KiB
Nix
64 lines
1.3 KiB
Nix
{ lib
|
|
, fetchFromGitHub
|
|
, python3Packages
|
|
, nixosTests
|
|
, testers
|
|
, sqlite3-to-mysql
|
|
, mysql80
|
|
}:
|
|
|
|
python3Packages.buildPythonApplication rec {
|
|
pname = "sqlite3-to-mysql";
|
|
version = "2.1.6";
|
|
format = "pyproject";
|
|
|
|
disabled = python3Packages.pythonOlder "3.8";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "techouse";
|
|
repo = pname;
|
|
rev = "refs/tags/v${version}";
|
|
hash = "sha256-RIe4If7R8snbNN2yIPxAh39EQplVyhMF2c0G06Zipds=";
|
|
};
|
|
|
|
nativeBuildInputs = with python3Packages; [
|
|
hatchling
|
|
];
|
|
|
|
propagatedBuildInputs = with python3Packages; [
|
|
click
|
|
mysql-connector
|
|
pytimeparse2
|
|
pymysql
|
|
pymysqlsa
|
|
simplejson
|
|
sqlalchemy
|
|
sqlalchemy-utils
|
|
tqdm
|
|
tabulate
|
|
unidecode
|
|
packaging
|
|
mysql80
|
|
];
|
|
|
|
# tests require a mysql server instance
|
|
doCheck = false;
|
|
|
|
# run package tests as a separate nixos test
|
|
passthru.tests = {
|
|
nixosTest = nixosTests.sqlite3-to-mysql;
|
|
version = testers.testVersion {
|
|
package = sqlite3-to-mysql;
|
|
command = "sqlite3mysql --version";
|
|
};
|
|
};
|
|
|
|
meta = with lib; {
|
|
description = "A simple Python tool to transfer data from SQLite 3 to MySQL";
|
|
homepage = "https://github.com/techouse/sqlite3-to-mysql";
|
|
license = licenses.mit;
|
|
maintainers = with maintainers; [ gador ];
|
|
mainProgram = "sqlite3mysql";
|
|
};
|
|
}
|