Skip to content

Commit

Permalink
Подключение setuptools_scm, небольшие фиксы
Browse files Browse the repository at this point in the history
  • Loading branch information
YariKartoshe4ka committed Jul 4, 2022
1 parent 0968add commit 55d56e6
Show file tree
Hide file tree
Showing 6 changed files with 31 additions and 11 deletions.
2 changes: 1 addition & 1 deletion .flake8
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
[flake8]
max-line-length = 120
max-line-length = 100
16 changes: 12 additions & 4 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,8 +1,16 @@
# Build artifacts
/vkms/version.py
build/
*.egg-info
dist/

# Python cache
__pycache__/
*.pyc

# Backups and sketches
other/
*.json

# Program artifacts
vkms-result*
build/
*.egg-info
dist/
*.json
1 change: 0 additions & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ repos:
- id: check-toml
- id: end-of-file-fixer
- id: trailing-whitespace
- id: requirements-txt-fixer

- repo: https://github.com/PyCQA/isort
rev: 5.10.1
Expand Down
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,8 @@ pip install vkms

- Сохранять переписки в программном формате (JSON), доступна многопоточная загрузка (`vkms dump`)
- Сохранять переписки в удобном для чтения формате (`vkms parse`)
- TXT, за основу была взята структура формата [hikiko4ern'а](https://github.com/hikiko4ern/vk_dump)
- HTML, кастомная верстка, максимально приближенная к официальному приложению VK Android
- Загружать вложения, доступна многопоточная загрузка (`vkms atch`)
- Фото
- Документы
Expand Down
14 changes: 10 additions & 4 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[build-system]
requires = ["setuptools"]
requires = ["setuptools>=45", "setuptools_scm[toml]>=6.2"]
build-backend = "setuptools.build_meta"

[project]
Expand All @@ -14,7 +14,7 @@ dependencies = [
"requests~=2.24",
"Jinja2~=3.1",
"minify-html~=0.8",
"vk>=3.0.dev"
"vk>=3.0"
]
urls.Homepage = "https://github.com/YariKartoshe4ka/vk-messages-saver"
readme = "README.md"
Expand Down Expand Up @@ -46,5 +46,11 @@ version = {attr = "vkms.__version__"}
[tool.setuptools.package-data]
vkms = ["templates/*.html"]

[tool.flake8]
max-line-length = 100
[tool.setuptools_scm]
write_to = "vkms/version.py"
write_to_template = '''
"""Version information"""
__version__ = '{version}'
__version_tuple__ = {version_tuple}
'''
7 changes: 6 additions & 1 deletion vkms/__init__.py
Original file line number Diff line number Diff line change
@@ -1 +1,6 @@
__version__ = '0.1.0'
from .version import __version__, __version_tuple__

__all__ = (
__version__,
__version_tuple__
)

0 comments on commit 55d56e6

Please sign in to comment.