-
Notifications
You must be signed in to change notification settings - Fork 20
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
Convert to an installable python package #148
Open
eric-wieser
wants to merge
6
commits into
master
Choose a base branch
from
python-module
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
2af08ca
Convert to an installable python package
eric-wieser 6afc657
Fix metadata
eric-wieser 9c5948f
fix import
eric-wieser 2850213
fix positional argument
eric-wieser 52d6271
Add entrypoint
eric-wieser 965781c
Update readme.md
eric-wieser File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,3 +6,5 @@ | |
/.vscode | ||
/.venv | ||
/__pycache__ | ||
|
||
*.egg-info |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
[build-system] | ||
requires = [ | ||
"setuptools>=42", | ||
"wheel" | ||
] | ||
build-backend = "setuptools.build_meta" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
[metadata] | ||
name = lean_doc_gen | ||
version = 0.0.1 | ||
author = Mathlib Community | ||
description = A documentation builder for lean code | ||
long_description = file: README.md | ||
long_description_content_type = text/markdown | ||
url = https://github.com/leanprover-community/doc-gen | ||
project_urls = | ||
Bug Tracker = https://github.com/leanprover-community/doc-gen/issues | ||
classifiers = | ||
Programming Language :: Python :: 3 | ||
License :: OSI Approved :: Apache Software License | ||
Operating System :: OS Independent | ||
|
||
[options] | ||
package_dir = | ||
=. | ||
packages = lean_doc_gen | ||
python_requires = >=3.8 | ||
install_requires = | ||
mistletoe>=0.7.2 | ||
toml | ||
mathlibtools | ||
pygments >= 2.7.1 | ||
jinja2 | ||
networkx | ||
pybtex>=0.22.2 | ||
latexcodec>=2.0.0 | ||
PyYAML>=5.3.1 | ||
six>=1.15.0 | ||
pylatexenc>=2.4 | ||
|
||
[options.package_data] | ||
lean_doc_gen = | ||
templates/*.j2 | ||
|
||
[options.entry_points] | ||
console_scripts = | ||
lean-doc-gen = lean_doc_gen:main |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please make it possible to run doc-gen and gen_docs without installing the package.
python -m lean_doc_gen
fails here.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why do we care about supporting non-installed packages?
Note that even with the package installed,
python -m lean_doc_gen
fails here; but that's only because it picks up the non-installed version in the current directory. If I movedlean_doc_gen
topython_src/lean_doc_gen
, or just changed the working directory when running this script, then that wouldn't happen.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Because I'm using that for development and I'm not keen on changing my ways. If we require installation then the readme must be updated. I believe there was a flag where pip just symlinks the package during installation, so that you don't need to reinstall after every change.