Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Decrease duplication and ensure dependencies are consistenly encoded in pyproject.toml #34

Merged
merged 2 commits into from
Nov 7, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .github/workflows/flit-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,8 @@ jobs:
python-version: 3.11
- name: Install flit
run: |
pip install flit>=3.9.0
pip install flit
flit install --only-deps

- name: Build and publish
run: |
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ jobs:
# so that coverage will be recorded for the module
run: |
pip install flit
flit install --deps=production --extras=test --pth-file
flit install --deps=all

- name: Run pytest
run: |
Expand Down
36 changes: 24 additions & 12 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,35 +2,47 @@
requires = ["flit_core >=2,<4"]
build-backend = "flit_core.buildapi"

[tool.flit.metadata]
module = "mdformat_frontmatter"
author = "Chris Butler"
author-email = "chris@thebutlers.me"
description-file = "README.md"
home-page = "https://github.com/butler54/mdformat-frontmatter"
[project]
name = "mdformat_frontmatter"
authors= [ {name = "Chris Butler", email = "chris@thebutlers.me"},

]
readme = "README.md"

classifiers = [
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Programming Language :: Python :: 3",
"Topic :: Software Development :: Libraries :: Python Modules",
]
keywords = "mdformat,markdown,markdown-it"
keywords = [
"mdformat",
"markdown",
"markdown-it"
]
dynamic = ["version", "description"]

requires-python=">=3.7"
requires=["mdformat >=0.7.16,<0.8.0",
dependencies=["mdformat >=0.7.16,<0.8.0",
"mdit-py-plugins >=0.4.0",
"ruamel.yaml"
]

[tool.flit.metadata.requires-extra]
[project.urls]
Source = "https://github.com/butler54/mdformat-frontmatter"
Changelog = "https://github.com/butler54/mdformat-frontmatter/blob/main/CHANGELOG.md"
[project.optional-dependencies]
test = [
"pytest>=7.3",
"coverage",
"pytest-cov"
]
dev = ["pre-commit"]
dev = [
"pre-commit",
"python-semantic-release >=8.3.0",
"flit >= 3.9"
]

[tool.flit.entrypoints."mdformat.parser_extension"]
[project.entry-points."mdformat.parser_extension"]
frontmatter = "mdformat_frontmatter"

[tool.flit.sdist]
Expand Down
15 changes: 15 additions & 0 deletions tests/fixtures.md
Original file line number Diff line number Diff line change
Expand Up @@ -113,3 +113,18 @@ somethingthatis: reallyreallyreallyreallyreallyreallyreallyreallyreallyreallyrea
somethingthatis: reallyreallyreallyreallyreallyreallyreallyreallyreallyreallyreallyreallyreallyreallyreallyreallyreallyreallyreallyreallyreallyreallylong
---
.

YAML parse error duplicate keys
.
---
] This is a YAML parse error
stuff: stuff
stuff: stuff
---
.
---
] This is a YAML parse error
stuff: stuff
stuff: stuff
---
.
Loading