Merge pull request #10 from eigenmagic/package
Package tool for PyPI/pip distribution.
This commit is contained in:
commit
9b187807e4
|
@ -0,0 +1,38 @@
|
||||||
|
[project]
|
||||||
|
name = "fediblockhole"
|
||||||
|
version = "0.2.1"
|
||||||
|
description = "Federated blocklist management for Mastodon"
|
||||||
|
readme = "README.md"
|
||||||
|
license = {file = "LICENSE"}
|
||||||
|
requires-python = ">=3.6"
|
||||||
|
keywords = ["mastodon", "fediblock"]
|
||||||
|
authors = [
|
||||||
|
{name = "Justin Warren"}, {email = "justin@eigenmagic.com"}
|
||||||
|
]
|
||||||
|
classifiers = [
|
||||||
|
"Development Status :: 3 - Alpha",
|
||||||
|
"Intended Audience :: Developers",
|
||||||
|
"Intended Audience :: System Administrators",
|
||||||
|
"License :: OSI Approved :: GNU Affero General Public License v3",
|
||||||
|
"Natural Language :: English",
|
||||||
|
"Programming Language :: Python :: 3",
|
||||||
|
"Programming Language :: Python :: 3.10",
|
||||||
|
]
|
||||||
|
dependencies = [
|
||||||
|
"requests",
|
||||||
|
"toml"
|
||||||
|
]
|
||||||
|
|
||||||
|
[project.urls]
|
||||||
|
homepage = "https://github.com/eigenmagic/fediblockhole"
|
||||||
|
documentation = "https://github.com/eigenmagic/fediblockhole"
|
||||||
|
repository = "https://github.com/eigenmagic/fediblockhole"
|
||||||
|
|
||||||
|
[project.scripts]
|
||||||
|
fediblock-sync = "fediblockhole:main"
|
||||||
|
|
||||||
|
[build-system]
|
||||||
|
requires = ["hatchling"]
|
||||||
|
build-backend = "hatchling.build"
|
||||||
|
# requires = ["flit_core >=3.4,<4"]
|
||||||
|
# build-backend = "flit_core.buildapi"
|
|
@ -1,5 +1,5 @@
|
||||||
#!/usr/bin/python3
|
"""A tool for managing federated Mastodon blocklists
|
||||||
# Export and import blocklists via API
|
"""
|
||||||
|
|
||||||
import argparse
|
import argparse
|
||||||
import toml
|
import toml
|
||||||
|
@ -571,7 +571,7 @@ def str2bool(boolstring: str) -> bool:
|
||||||
else:
|
else:
|
||||||
raise ValueError(f"Cannot parse value '{boolstring}' as boolean")
|
raise ValueError(f"Cannot parse value '{boolstring}' as boolean")
|
||||||
|
|
||||||
if __name__ == '__main__':
|
def main():
|
||||||
|
|
||||||
ap = argparse.ArgumentParser(description="Bulk blocklist tool",
|
ap = argparse.ArgumentParser(description="Bulk blocklist tool",
|
||||||
formatter_class=argparse.ArgumentDefaultsHelpFormatter)
|
formatter_class=argparse.ArgumentDefaultsHelpFormatter)
|
Loading…
Reference in New Issue