##// END OF EJS Templates
core(project): updated pyproject structure for formatting/linting
super-admin -
r5642:83572a1b default
parent child Browse files
Show More
@@ -1,131 +1,137
1 [build-system]
1 [build-system]
2 requires = ["setuptools>=61.0.0", "wheel", "pastescript"]
2 requires = ["setuptools>=61.0.0", "wheel", "pastescript"]
3 build-backend = "setuptools.build_meta"
3 build-backend = "setuptools.build_meta"
4
4
5 [project]
5 [project]
6 name = "rhodecode-enterprise-ce"
6 name = "rhodecode-enterprise-ce"
7 description = "Enterprise Source Code Management Platform"
7 description = "Enterprise Source Code Management Platform"
8 authors = [
8 authors = [
9 {name = "RhodeCode GmbH", email = "support@rhodecode.com"},
9 {name = "RhodeCode GmbH", email = "support@rhodecode.com"},
10 ]
10 ]
11 keywords = [
11 keywords = [
12 'rhodecode', 'mercurial', 'git', 'svn',
12 'rhodecode', 'mercurial', 'git', 'svn',
13 'code review',
13 'code review',
14 'repo groups', 'ldap', 'repository management', 'hgweb',
14 'repo groups', 'ldap', 'repository management', 'hgweb',
15 'hgwebdir', 'gitweb', 'serving hgweb',
15 'hgwebdir', 'gitweb', 'serving hgweb',
16 ]
16 ]
17 license = {text = "GPL V3"}
17 license = {text = "GPL V3"}
18 requires-python = ">=3.10"
18 requires-python = ">=3.10"
19 dynamic = ["version", "readme", "dependencies", "optional-dependencies"]
19 dynamic = ["version", "readme", "dependencies", "optional-dependencies"]
20 classifiers = [
20 classifiers = [
21 'Development Status :: 6 - Mature',
21 'Development Status :: 6 - Mature',
22 'Intended Audience :: Developers',
22 'Intended Audience :: Developers',
23 'Operating System :: OS Independent',
23 'Operating System :: OS Independent',
24 'Topic :: Software Development :: Version Control',
24 'Topic :: Software Development :: Version Control',
25 'License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)',
25 'License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)',
26 'Programming Language :: Python :: 3.10',
26 'Programming Language :: Python :: 3.11',
27 ]
27 ]
28
28
29 [project.entry-points."paste.app_factory"]
29 [project.entry-points."paste.app_factory"]
30 main = "rhodecode.config.middleware:make_pyramid_app"
30 main = "rhodecode.config.middleware:make_pyramid_app"
31
31
32 [project.entry-points."pyramid.pshell_runner"]
32 [project.entry-points."pyramid.pshell_runner"]
33 ipython = "rhodecode.lib.pyramid_shell:ipython_shell_runner"
33 ipython = "rhodecode.lib.pyramid_shell:ipython_shell_runner"
34
34
35 [project.entry-points."beaker.backends"]
35 [project.entry-points."beaker.backends"]
36 memorylru_base="rhodecode.lib.memory_lru_dict:MemoryLRUNamespaceManagerBase"
36 memorylru_base="rhodecode.lib.memory_lru_dict:MemoryLRUNamespaceManagerBase"
37 memorylru_debug="rhodecode.lib.memory_lru_dict:MemoryLRUNamespaceManagerDebug"
37 memorylru_debug="rhodecode.lib.memory_lru_dict:MemoryLRUNamespaceManagerDebug"
38
38
39 [project.scripts]
39 [project.scripts]
40
40
41 rc-setup-app = "rhodecode.lib.rc_commands.setup_rc:main"
41 rc-setup-app = "rhodecode.lib.rc_commands.setup_rc:main"
42 rc-upgrade-db = "rhodecode.lib.rc_commands.upgrade_db:main"
42 rc-upgrade-db = "rhodecode.lib.rc_commands.upgrade_db:main"
43 rc-ishell = "rhodecode.lib.rc_commands.ishell:main"
43 rc-ishell = "rhodecode.lib.rc_commands.ishell:main"
44 rc-add-artifact = "rhodecode.lib.rc_commands.add_artifact:main"
44 rc-add-artifact = "rhodecode.lib.rc_commands.add_artifact:main"
45 rc-migrate-artifact = "rhodecode.lib.rc_commands.migrate_artifact:main"
45 rc-migrate-artifact = "rhodecode.lib.rc_commands.migrate_artifact:main"
46 rc-ssh-wrapper = "rhodecode.apps.ssh_support.lib.ssh_wrapper_v1:main"
46 rc-ssh-wrapper = "rhodecode.apps.ssh_support.lib.ssh_wrapper_v1:main"
47 rc-ssh-wrapper-v2 = "rhodecode.apps.ssh_support.lib.ssh_wrapper_v2:main"
47 rc-ssh-wrapper-v2 = "rhodecode.apps.ssh_support.lib.ssh_wrapper_v2:main"
48
48
49 [tool.setuptools]
49 [tool.setuptools]
50 packages = ["rhodecode"]
50 packages = ["rhodecode"]
51 include-package-data = true
51 include-package-data = true
52
52
53 [tools.setuptools.package-data]
53 [tools.setuptools.package-data]
54 "" = ['*.txt', '*.rst']
54 "" = ['*.txt', '*.rst']
55 "configs" = ['*.ini']
55 "configs" = ['*.ini']
56 "rhodecode" = ['VERSION', 'i18n/*/LC_MESSAGES/*.mo', ]
56 "rhodecode" = ['VERSION', 'i18n/*/LC_MESSAGES/*.mo', ]
57
57
58 [tool.setuptools.exclude-package-data]
58 [tool.setuptools.exclude-package-data]
59 "rhodecode" = ["__pycache__"]
59 "rhodecode" = ["__pycache__"]
60
60
61 [tool.setuptools.dynamic]
61 [tool.setuptools.dynamic]
62 readme = {file = ["README.rst"], content-type = "text/rst"}
62 readme = {file = ["README.rst"], content-type = "text/rst"}
63 version = {file = "rhodecode/VERSION"}
63 version = {file = "rhodecode/VERSION"}
64 dependencies = {file = ["requirements.txt"]}
64 dependencies = {file = ["requirements.txt"]}
65 optional-dependencies.tests = {file = ["requirements_test.txt"]}
65 optional-dependencies.tests = {file = ["requirements_test.txt"]}
66
66
67 [tool.ruff]
67 [tool.ruff]
68 lint.select = [
68 # Line length max same as Black.
69 line-length = 120
70
71 # Assume Python 3.11
72 target-version = "py311"
73
74
75 [tool.ruff.lint]
76 select = [
69 # Pyflakes
77 # Pyflakes
70 "F",
78 "F",
71 # Pycodestyle
79 # Pycodestyle
72 "E",
80 "E",
73 "W",
81 "W",
74 # isort
82 # isort
75 "I001"
83 "I001"
76 ]
84 ]
77 lint.ignore = [
85
86 ignore = [
78 "E501", # line too long, handled by black
87 "E501", # line too long, handled by black
79 ]
88 ]
80 # Same as Black.
81 line-length = 120
82
89
83 [tool.ruff.lint.isort]
90 [tool.ruff.lint.isort]
84 known-first-party = ["rhodecode"]
91 known-first-party = ["rhodecode"]
85
92
86 [tool.ruff.format]
93 [tool.ruff.format]
87
88 # Like Black, use double quotes for strings.
94 # Like Black, use double quotes for strings.
89 quote-style = "double"
95 quote-style = "double"
90
96
91 # Like Black, indent with spaces, rather than tabs.
97 # Like Black, indent with spaces, rather than tabs.
92 indent-style = "space"
98 indent-style = "space"
93
99
94 # Like Black, respect magic trailing commas.
100 # Like Black, respect magic trailing commas.
95 skip-magic-trailing-comma = false
101 skip-magic-trailing-comma = false
96
102
97 # Like Black, automatically detect the appropriate line ending.
103 # Like Black, automatically detect the appropriate line ending.
98 line-ending = "auto"
104 line-ending = "auto"
99
105
100
106
101 [tool.bumpversion]
107 [tool.bumpversion]
102 current_version = "5.4.0"
108 current_version = "5.4.0"
103 parse = "(?P<major>\\d+)\\.(?P<minor>\\d+)\\.(?P<patch>\\d+)"
109 parse = "(?P<major>\\d+)\\.(?P<minor>\\d+)\\.(?P<patch>\\d+)"
104 serialize = ["{major}.{minor}.{patch}"]
110 serialize = ["{major}.{minor}.{patch}"]
105 search = "{current_version}"
111 search = "{current_version}"
106 replace = "{new_version}"
112 replace = "{new_version}"
107 regex = false
113 regex = false
108 ignore_missing_version = false
114 ignore_missing_version = false
109 ignore_missing_files = false
115 ignore_missing_files = false
110 tag = false
116 tag = false
111 sign_tags = false
117 sign_tags = false
112 tag_name = "v{new_version}"
118 tag_name = "v{new_version}"
113 tag_message = "release(version-bump): {current_version} → {new_version}"
119 tag_message = "release(version-bump): {current_version} → {new_version}"
114 allow_dirty = false
120 allow_dirty = false
115 commit = false
121 commit = false
116 message = "release(version-bump): {current_version} → {new_version}"
122 message = "release(version-bump): {current_version} → {new_version}"
117 commit_args = ""
123 commit_args = ""
118 setup_hooks = []
124 setup_hooks = []
119 pre_commit_hooks = []
125 pre_commit_hooks = []
120 post_commit_hooks = []
126 post_commit_hooks = []
121
127
122
128
123 # message_extractors={
129 # message_extractors={
124 # 'rhodecode': [
130 # 'rhodecode': [
125 # ('**.py', 'python', None),
131 # ('**.py', 'python', None),
126 # ('**.js', 'javascript', None),
132 # ('**.js', 'javascript', None),
127 # ('templates/**.mako', 'mako', {'input_encoding': 'utf-8'}),
133 # ('templates/**.mako', 'mako', {'input_encoding': 'utf-8'}),
128 # ('templates/**.html', 'mako', {'input_encoding': 'utf-8'}),
134 # ('templates/**.html', 'mako', {'input_encoding': 'utf-8'}),
129 # ('public/**', 'ignore', None),
135 # ('public/**', 'ignore', None),
130 # ]
136 # ]
131 # },
137 # },
General Comments 0
You need to be logged in to leave comments. Login now