Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit1da7741

Browse files
authored
Merge pull request#1337 from Yobmod/main
Import README.md into setup.py
2 parentscfcae1d +bc2edef commit1da7741

File tree

1 file changed

+12
-9
lines changed

1 file changed

+12
-9
lines changed

‎setup.py

Lines changed: 12 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,8 @@
55
importfnmatch
66
importos
77
importsys
8-
fromosimportpath
98

10-
withopen(path.join(path.dirname(__file__),'VERSION'))asv:
9+
withopen(os.path.join(os.path.dirname(__file__),'VERSION'))asv:
1110
VERSION=v.readline().strip()
1211

1312
withopen('requirements.txt')asreqs_file:
@@ -16,12 +15,15 @@
1615
withopen('test-requirements.txt')asreqs_file:
1716
test_requirements=reqs_file.read().splitlines()
1817

18+
withopen('README.md')asrm_file:
19+
long_description=rm_file.read()
20+
1921

2022
classbuild_py(_build_py):
2123

2224
defrun(self)->None:
23-
init=path.join(self.build_lib,'git','__init__.py')
24-
ifpath.exists(init):
25+
init=os.path.join(self.build_lib,'git','__init__.py')
26+
ifos.path.exists(init):
2527
os.unlink(init)
2628
_build_py.run(self)
2729
_stamp_version(init)
@@ -32,10 +34,10 @@ class sdist(_sdist):
3234

3335
defmake_release_tree(self,base_dir:str,files:Sequence)->None:
3436
_sdist.make_release_tree(self,base_dir,files)
35-
orig=path.join('git','__init__.py')
36-
assertpath.exists(orig),orig
37-
dest=path.join(base_dir,orig)
38-
ifhasattr(os,'link')andpath.exists(dest):
37+
orig=os.path.join('git','__init__.py')
38+
assertos.path.exists(orig),orig
39+
dest=os.path.join(base_dir,orig)
40+
ifhasattr(os,'link')andos.path.exists(dest):
3941
os.unlink(dest)
4042
self.copy_file(orig,dest)
4143
_stamp_version(dest)
@@ -82,7 +84,7 @@ def build_py_modules(basedir: str, excludes: Sequence = ()) -> Sequence:
8284
name="GitPython",
8385
cmdclass={'build_py':build_py,'sdist':sdist},
8486
version=VERSION,
85-
description="PythonGitLibrary",
87+
description="""GitPython is a python library used to interact withGitrepositories""",
8688
author="Sebastian Thiel, Michael Trier",
8789
author_email="byronimo@gmail.com, mtrier@gmail.com",
8890
license="BSD",
@@ -96,6 +98,7 @@ def build_py_modules(basedir: str, excludes: Sequence = ()) -> Sequence:
9698
tests_require=requirements+test_requirements,
9799
zip_safe=False,
98100
long_description="""GitPython is a python library used to interact with Git repositories""",
101+
long_description_content_type="text/markdown",
99102
classifiers=[
100103
# Picked from
101104
# http://pypi.python.org/pypi?:action=list_classifiers

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp