mirror of
https://github.com/Findus23/pyLanguagetool.git
synced 2024-09-09 04:13:46 +02:00
drop python2 and use poetry for development
This commit is contained in:
parent
d10c68d2ef
commit
5f0a37c166
16 changed files with 57 additions and 68 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -94,3 +94,4 @@ ENV/
|
|||
.ropeproject
|
||||
|
||||
.mypy_cache/
|
||||
poetry.lock
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
image: python:3.7
|
||||
image: python:3.8
|
||||
|
||||
before_script:
|
||||
- pip install -e .[dev]
|
||||
|
|
|
@ -1,4 +0,0 @@
|
|||
# autogenerated pyup.io config file
|
||||
# see https://pyup.io/docs/configuration/ for all available options
|
||||
|
||||
schedule: every week
|
|
@ -1,7 +1,6 @@
|
|||
language: python
|
||||
dist: xenial
|
||||
python:
|
||||
- "2.7"
|
||||
- "3.5"
|
||||
- "3.6"
|
||||
- "3.7"
|
||||
|
|
|
@ -1,6 +1,12 @@
|
|||
Changelog
|
||||
=========
|
||||
|
||||
`0.9.0` (2020-01-23)
|
||||
--------------------
|
||||
* drop support for Python 2
|
||||
* improve XLIFF handling
|
||||
|
||||
|
||||
`0.8.4` (2019-11-15)
|
||||
--------------------
|
||||
* support Python 3.8
|
||||
|
|
|
@ -12,8 +12,6 @@ variety of languages and has advanced grammar support.
|
|||
|
||||
.. start-of-homepage-text
|
||||
|
||||
**Warning:** The first release in 2020 will drop Python 2 support.
|
||||
|
||||
Installation
|
||||
------------
|
||||
pyLanguagetool can be installed with pip/pipenv:
|
||||
|
|
|
@ -7,11 +7,9 @@ environment:
|
|||
# The list here is complete (excluding Python 2.6, which
|
||||
# isn't covered by this document) at the time of writing.
|
||||
|
||||
- PYTHON: "C:\\Python27"
|
||||
- PYTHON: "C:\\Python35"
|
||||
- PYTHON: "C:\\Python36"
|
||||
- PYTHON: "C:\\Python37"
|
||||
- PYTHON: "C:\\Python27-x64"
|
||||
- PYTHON: "C:\\Python35-x64"
|
||||
- PYTHON: "C:\\Python36-x64"
|
||||
- PYTHON: "C:\\Python37-x64"
|
||||
|
|
|
@ -1,7 +1,6 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
"""A python library and CLI tool for the LanguageTool JSON API."""
|
||||
from __future__ import print_function
|
||||
|
||||
"""
|
||||
A python library and CLI tool for the LanguageTool JSON API.
|
||||
"""
|
||||
import os
|
||||
import sys
|
||||
from pprint import pprint
|
||||
|
@ -91,10 +90,7 @@ def get_clipboard():
|
|||
|
||||
"""
|
||||
# See also: http://stackoverflow.com/a/16189232
|
||||
try:
|
||||
import Tkinter as tk # Python2
|
||||
except ImportError:
|
||||
import tkinter as tk # Python3
|
||||
import tkinter as tk
|
||||
|
||||
root = tk.Tk()
|
||||
root.withdraw() # keep the window from showing
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
r"""
|
||||
Python API wrapper for the languagetool REST API.
|
||||
|
||||
|
|
23
pyproject.toml
Normal file
23
pyproject.toml
Normal file
|
@ -0,0 +1,23 @@
|
|||
[tool.poetry]
|
||||
name = "pylanguagetool"
|
||||
version = "0.9.0"
|
||||
description = "A python library and CLI for the LanguageTool JSON API"
|
||||
authors = ["Lukas Winkler <git@lw1.at>"]
|
||||
license = "MIT"
|
||||
|
||||
[tool.poetry.dependencies]
|
||||
python = ">=3.5,<3.9"
|
||||
colorama = ">=0.4.1"
|
||||
configargparse = ">=0.14.0"
|
||||
requests = ">=2.22.0"
|
||||
|
||||
[tool.poetry.dev-dependencies]
|
||||
pytest = "^5.3.4"
|
||||
docutils = "^0.16"
|
||||
markdown2 = "^2.3.8"
|
||||
beautifulsoup4 = "^4.8.2"
|
||||
sphinx = "^2.3.1"
|
||||
|
||||
[build-system]
|
||||
requires = ["poetry>=0.12"]
|
||||
build-backend = "poetry.masonry.api"
|
|
@ -1,38 +1,24 @@
|
|||
appdirs==1.4.3
|
||||
args==0.1.0
|
||||
atomicwrites==1.1.5
|
||||
attrs==18.1.0
|
||||
beautifulsoup4==4.8.0
|
||||
bleach==3.1.0
|
||||
certifi==2019.9.11
|
||||
atomicwrites==1.3.0; sys_platform == "win32"
|
||||
attrs==19.3.0
|
||||
beautifulsoup4==4.8.2
|
||||
certifi==2019.11.28
|
||||
chardet==3.0.4
|
||||
clint==0.5.1
|
||||
colorama==0.4.1
|
||||
ConfigArgParse==0.14.0
|
||||
dnspython==1.16.0
|
||||
docutils==0.14
|
||||
docutils-stubs==0.0.21
|
||||
future==0.17.1
|
||||
colorama==0.4.3
|
||||
configargparse==1.0
|
||||
docutils==0.16
|
||||
idna==2.8
|
||||
importlib-metadata==0.18
|
||||
importlib-metadata==1.4.0; python_version < "3.8"
|
||||
markdown2==2.3.8
|
||||
more-itertools==4.3.0
|
||||
packaging==19.2
|
||||
pkginfo==1.5.0.1
|
||||
pluggy==0.12.0
|
||||
py==1.5.4
|
||||
Pygments==2.4.2
|
||||
pyparsing==2.2.0
|
||||
pytest==5.1.2
|
||||
pyxdg==0.26
|
||||
readme-renderer==24.0
|
||||
more-itertools==8.1.0
|
||||
packaging==20.0
|
||||
pathlib2==2.3.5; python_version < "3.6"
|
||||
pluggy==0.13.1
|
||||
py==1.8.1
|
||||
pyparsing==2.4.6
|
||||
pytest==5.3.4
|
||||
requests==2.22.0
|
||||
requests-toolbelt==0.9.1
|
||||
six==1.12.0
|
||||
soupsieve==1.9.1
|
||||
tqdm==4.32.2
|
||||
twine==1.15.0
|
||||
urllib3==1.25.4
|
||||
wcwidth==0.1.7
|
||||
webencodings==0.5.1
|
||||
zipp==0.5.2
|
||||
six==1.14.0
|
||||
soupsieve==1.9.5
|
||||
urllib3==1.25.8
|
||||
wcwidth==0.1.8
|
||||
zipp==1.0.0; python_version < "3.8"
|
||||
|
|
|
@ -3,13 +3,6 @@
|
|||
[options]
|
||||
setup_requires =
|
||||
sphinx;python_version>"3.4"
|
||||
sphinx<2;python_version<="3.4"
|
||||
|
||||
[bdist_wheel]
|
||||
# This flag says that the code is written to work on both Python 2 and Python
|
||||
# 3. If at all possible, it is good practice to do this. If you cannot, you
|
||||
# will need to generate wheels for each Python version that you support.
|
||||
universal=1
|
||||
|
||||
[build_sphinx]
|
||||
source-dir = docs
|
||||
|
|
6
setup.py
6
setup.py
|
@ -12,7 +12,7 @@ with open(path.join(here, 'README.rst'), encoding='utf-8') as f:
|
|||
|
||||
setup(
|
||||
name='pyLanguagetool',
|
||||
version='0.8.4',
|
||||
version='0.9.0',
|
||||
packages=find_packages(),
|
||||
url='https://pylanguagetool.lw1.at/',
|
||||
license='MIT',
|
||||
|
@ -24,8 +24,6 @@ setup(
|
|||
'Development Status :: 4 - Beta',
|
||||
'License :: OSI Approved :: MIT License',
|
||||
'Environment :: Console',
|
||||
'Programming Language :: Python :: 2',
|
||||
'Programming Language :: Python :: 2.7',
|
||||
'Programming Language :: Python :: 3',
|
||||
'Programming Language :: Python :: 3.5',
|
||||
'Programming Language :: Python :: 3.6',
|
||||
|
@ -37,7 +35,7 @@ setup(
|
|||
],
|
||||
install_requires=['colorama>=0.4.1', 'configargparse>=0.14.0', 'requests>=2.22.0'],
|
||||
extras_require={
|
||||
'dev': ["pytest", "docutils", "pygments"],
|
||||
'dev': ["pytest"],
|
||||
'optional': ["beautifulsoup4", "markdown2", "docutils"],
|
||||
},
|
||||
keywords="languagetool spell grammar checker",
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
import os
|
||||
|
||||
from pylanguagetool import api
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
import pylanguagetool
|
||||
|
||||
|
||||
|
|
|
@ -1,5 +1,3 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
|
||||
from pylanguagetool import converters
|
||||
|
||||
markdown = """# Heading
|
||||
|
|
Loading…
Reference in a new issue