From e80dee57e8e1cfdc5de948da6fd9a1c2f8909a8c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Damir=20Jeli=C4=87?= Date: Fri, 20 Mar 2020 22:03:37 +0100 Subject: [PATCH] weechat-matrix: Add a poetry file so we can create a release tarball. --- README.md | 10 +++--- contrib/{matrix_decrypt => matrix_decrypt.py} | 0 ...matrix_sso_helper => matrix_sso_helper.py} | 0 contrib/{matrix_upload => matrix_upload.py} | 0 pyproject.toml | 33 +++++++++++++++++++ 5 files changed, 38 insertions(+), 5 deletions(-) rename contrib/{matrix_decrypt => matrix_decrypt.py} (100%) rename contrib/{matrix_sso_helper => matrix_sso_helper.py} (100%) rename contrib/{matrix_upload => matrix_upload.py} (100%) create mode 100644 pyproject.toml diff --git a/README.md b/README.md index 4846a23..3d06053 100644 --- a/README.md +++ b/README.md @@ -114,13 +114,13 @@ would have been copied using `make install`. ## Uploading files Uploads are done using a helper script, which is found under -[contrib/matrix_upload](https://github.com/poljar/weechat-matrix/blob/master/contrib/matrix_upload). -We recommend you install this under your `PATH`. +[contrib/matrix_upload](https://github.com/poljar/weechat-matrix/blob/master/contrib/matrix_upload.py). +We recommend you install this under your `PATH` as `matrix_upload`. ## Downloading encrypted files Encrypted files can be opened by passing the displayed `emxc://` URI to the -[contrib/matrix_decrypt](https://github.com/poljar/weechat-matrix/blob/master/contrib/matrix_decrypt) +[contrib/matrix_decrypt](https://github.com/poljar/weechat-matrix/blob/master/contrib/matrix_decrypt.py) helper script. # Configuration @@ -162,8 +162,8 @@ Configuration is completed primarily through the Weechat interface. First start ## Single sign-on: Single sign-on is supported using a helper script, the script found under -[contrib/matrix_sso_helper](https://github.com/poljar/weechat-matrix/blob/master/contrib/matrix_sso_helper) -should be installed under your `PATH`. +[contrib/matrix_sso_helper](https://github.com/poljar/weechat-matrix/blob/master/contrib/matrix_sso_helper.py) +should be installed under your `PATH` as `matrix_sso_helper`. For single sign-on to be the preferred leave the servers username and password empty. diff --git a/contrib/matrix_decrypt b/contrib/matrix_decrypt.py similarity index 100% rename from contrib/matrix_decrypt rename to contrib/matrix_decrypt.py diff --git a/contrib/matrix_sso_helper b/contrib/matrix_sso_helper.py similarity index 100% rename from contrib/matrix_sso_helper rename to contrib/matrix_sso_helper.py diff --git a/contrib/matrix_upload b/contrib/matrix_upload.py similarity index 100% rename from contrib/matrix_upload rename to contrib/matrix_upload.py diff --git a/pyproject.toml b/pyproject.toml new file mode 100644 index 0000000..addc1f7 --- /dev/null +++ b/pyproject.toml @@ -0,0 +1,33 @@ +[tool.poetry] +name = "matrix" +version = "0.1.0" +license = "ISC" +description = "Weechat protocol script for Matrix." +authors = ["Damir Jelić "] +packages = [ + { include = "matrix" }, + { include = "contrib/*.py" }, + { include = "main.py" }, +] + +[tool.poetry.dependencies] +python = "^3.8" +pyOpenSSL = "^19.1.0" +webcolors = "^1.11.1" +atomicwrites = "^1.3.0" +future = "^0.18.2" +attrs = "^19.3.0" +logbook = "^1.5.3" +pygments = "^2.6.1" +matrix-nio = "^0.9.0" +python-magic = "^0.4.15" +aiohttp = "^3.6.2" +requests = "^2.23.0" +typing = "^3.7.4; python_version < 3.5" + +[tool.poetry.scripts] +matrix_decrypt = 'contrib/matrix_decrypt:main' + +[build-system] +requires = ["poetry>=0.12"] +build-backend = "poetry.masonry.api"