2020-07-29 17:08:56 -04:00
|
|
|
|
[build-system]
|
2022-05-10 21:09:43 +05:30
|
|
|
|
# PEP 518 https://www.python.org/dev/peps/pep-0518/
|
|
|
|
|
# https://discuss.python.org/t/help-testing-experimental-features-in-setuptools/13821
|
|
|
|
|
requires = ["setuptools>=61", "wheel"]
|
|
|
|
|
# PEP 517 https://peps.python.org/pep-0517/
|
|
|
|
|
build-backend = "setuptools.build_meta"
|
|
|
|
|
|
|
|
|
|
[project]
|
|
|
|
|
# PEP 621 project metadata
|
|
|
|
|
# See https://www.python.org/dev/peps/pep-0621/
|
|
|
|
|
name = "xonsh"
|
|
|
|
|
dynamic = ["version", "readme"]
|
2024-07-10 16:34:23 +02:00
|
|
|
|
description = "Python-powered shell. Full-featured and cross-platform."
|
2022-05-10 21:09:43 +05:30
|
|
|
|
authors = [{ name = "Anthony Scopatz" }, { email = "scopatz@gmail.com" }]
|
2024-07-17 07:43:08 -07:00
|
|
|
|
maintainers = [{ name = "Xonsh Community" }, { email = "xonsh@gil.forsyth.dev" }]
|
2022-06-29 18:43:43 +05:30
|
|
|
|
license = { text = "BSD 2-Clause License" }
|
2023-07-04 22:18:37 +05:30
|
|
|
|
requires-python = ">=3.9"
|
2024-12-08 09:28:31 +01:00
|
|
|
|
dependencies = []
|
2022-05-10 21:09:43 +05:30
|
|
|
|
|
|
|
|
|
[tool.setuptools.dynamic]
|
|
|
|
|
version = {attr = "xonsh.__version__"}
|
|
|
|
|
readme = {file = ["README.rst"]}
|
|
|
|
|
|
|
|
|
|
[tool.setuptools]
|
|
|
|
|
packages = [
|
|
|
|
|
"xonsh",
|
2024-06-29 11:58:11 +02:00
|
|
|
|
"xonsh.api",
|
2024-06-29 10:56:50 +02:00
|
|
|
|
"xonsh.shells",
|
|
|
|
|
"xonsh.shells.ptk_shell",
|
2024-06-29 10:28:02 +02:00
|
|
|
|
"xonsh.parsers.ply",
|
2022-05-10 21:09:43 +05:30
|
|
|
|
"xonsh.procs",
|
2024-07-01 13:44:38 +02:00
|
|
|
|
"xonsh.platforms",
|
2022-05-10 21:09:43 +05:30
|
|
|
|
"xonsh.parsers",
|
|
|
|
|
"xonsh.xoreutils",
|
|
|
|
|
"xontrib",
|
|
|
|
|
"xonsh.completers",
|
|
|
|
|
"xonsh.history",
|
|
|
|
|
"xonsh.prompt",
|
|
|
|
|
"xonsh.pytest",
|
|
|
|
|
"xonsh.lib",
|
|
|
|
|
"xonsh.webconfig",
|
|
|
|
|
"xonsh.virtualenv",
|
|
|
|
|
"xompletions",
|
|
|
|
|
]
|
|
|
|
|
platforms = ["Cross Platform"]
|
|
|
|
|
include-package-data = false
|
|
|
|
|
|
|
|
|
|
[tool.setuptools.package-dir]
|
|
|
|
|
xonsh = "xonsh"
|
|
|
|
|
xontrib = "xontrib"
|
|
|
|
|
xompletions = "xompletions"
|
|
|
|
|
"xonsh.lib" = "xonsh/lib"
|
|
|
|
|
"xonsh.webconfig" = "xonsh/webconfig"
|
|
|
|
|
|
|
|
|
|
[tool.setuptools.package-data]
|
|
|
|
|
xonsh = [
|
|
|
|
|
"*.json",
|
|
|
|
|
"*.githash",
|
|
|
|
|
]
|
|
|
|
|
xontrib = ["*.xsh"]
|
|
|
|
|
"xonsh.lib" = ["*.xsh"]
|
|
|
|
|
"xonsh.virtualenv" = ["*.xsh"]
|
|
|
|
|
"xonsh.webconfig" = [
|
|
|
|
|
"*.html",
|
|
|
|
|
"js/app.min.js",
|
|
|
|
|
"js/bootstrap.min.css",
|
|
|
|
|
"js/LICENSE-bootstrap",
|
2023-03-04 19:53:53 +05:30
|
|
|
|
"js/xonsh_sticker_mini.png",
|
2022-05-10 21:09:43 +05:30
|
|
|
|
]
|
|
|
|
|
|
|
|
|
|
[project.entry-points]
|
|
|
|
|
pytest11 = { xonsh = "xonsh.pytest.plugin" }
|
|
|
|
|
|
|
|
|
|
[project.entry-points."pygments.lexers"]
|
|
|
|
|
xonsh = "xonsh.pyghooks:XonshLexer"
|
|
|
|
|
xonshcon = "xonsh.pyghooks:XonshConsoleLexer"
|
|
|
|
|
|
|
|
|
|
[project.entry-points."virtualenv.activate"]
|
|
|
|
|
xonsh = "xonsh.virtualenv:XonshActivator"
|
|
|
|
|
|
|
|
|
|
[project.urls]
|
|
|
|
|
Homepage = "https://xon.sh"
|
|
|
|
|
documentation = "https://xon.sh/contents.html"
|
|
|
|
|
repository = "https://github.com/xonsh/xonsh"
|
|
|
|
|
changelog = "https://github.com/xonsh/xonsh/blob/main/CHANGELOG.rst"
|
|
|
|
|
"Issue tracker" = "https://github.com/xonsh/xonsh/issues"
|
|
|
|
|
|
|
|
|
|
[project.optional-dependencies]
|
|
|
|
|
ptk = [
|
2024-05-23 20:08:54 +02:00
|
|
|
|
"prompt-toolkit>=3.0.29",
|
2022-05-10 21:09:43 +05:30
|
|
|
|
"pyperclip",
|
|
|
|
|
]
|
|
|
|
|
pygments = ["pygments>=2.2"]
|
|
|
|
|
mac = ["gnureadline"]
|
|
|
|
|
linux = ["distro"]
|
|
|
|
|
proctitle = ["setproctitle"]
|
|
|
|
|
full = [
|
|
|
|
|
"xonsh[ptk,pygments]",
|
|
|
|
|
"distro; platform_system=='Linux'",
|
|
|
|
|
"setproctitle; platform_system=='Windows'",
|
|
|
|
|
"gnureadline; platform_system=='Darwin'",
|
2022-08-03 19:24:19 +06:00
|
|
|
|
"ujson",
|
2022-05-10 21:09:43 +05:30
|
|
|
|
]
|
|
|
|
|
bestshell = [
|
2024-05-23 20:08:54 +02:00
|
|
|
|
"prompt-toolkit>=3.0.29",
|
2022-05-10 21:09:43 +05:30
|
|
|
|
"pygments>=2.2",
|
|
|
|
|
]
|
|
|
|
|
test = [
|
|
|
|
|
"xonsh[bestshell]",
|
|
|
|
|
"pytest>=7",
|
|
|
|
|
"restructuredtext_lint",
|
|
|
|
|
"pytest-cov",
|
|
|
|
|
"pytest-mock",
|
|
|
|
|
"pytest-timeout",
|
|
|
|
|
"pytest-subprocess",
|
|
|
|
|
"pytest-rerunfailures",
|
2024-05-23 20:08:54 +02:00
|
|
|
|
"prompt-toolkit>=3.0.29",
|
2022-05-10 21:09:43 +05:30
|
|
|
|
"pygments>=2.2",
|
|
|
|
|
"coverage>=5.3.1",
|
|
|
|
|
"pyte>=0.8.0",
|
2022-07-31 01:02:01 -04:00
|
|
|
|
"virtualenv>=20.16.2",
|
2024-03-18 23:16:25 +05:30
|
|
|
|
"requests",
|
2022-05-10 21:09:43 +05:30
|
|
|
|
]
|
|
|
|
|
dev = [
|
2022-07-01 21:17:01 +05:30
|
|
|
|
"xonsh[test,doc]",
|
2022-05-10 21:09:43 +05:30
|
|
|
|
"pre-commit",
|
|
|
|
|
"re-ver",
|
|
|
|
|
"tomli",
|
|
|
|
|
]
|
|
|
|
|
doc = [
|
|
|
|
|
"xonsh[bestshell]",
|
2022-05-18 11:06:45 -04:00
|
|
|
|
"furo",
|
2022-05-10 21:09:43 +05:30
|
|
|
|
"numpydoc",
|
2023-12-17 09:32:02 -08:00
|
|
|
|
"sphinx>=3.1",
|
2022-05-10 21:09:43 +05:30
|
|
|
|
"psutil",
|
|
|
|
|
"pyzmq",
|
|
|
|
|
"matplotlib",
|
|
|
|
|
"tornado",
|
|
|
|
|
"runthis-sphinxext",
|
|
|
|
|
"livereload",
|
|
|
|
|
"myst-parser",
|
|
|
|
|
]
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
[project.scripts]
|
|
|
|
|
xonsh = "xonsh.main:main"
|
|
|
|
|
xonsh-cat = "xonsh.xoreutils.cat:main"
|
|
|
|
|
xonsh-uname = "xonsh.xoreutils.uname:main"
|
|
|
|
|
xonsh-uptime = "xonsh.xoreutils.uptime:main"
|
|
|
|
|
|
2020-07-29 17:08:56 -04:00
|
|
|
|
|
2024-04-15 17:40:17 +05:30
|
|
|
|
[tool.ruff.lint.isort]
|
2023-04-19 18:29:32 +05:30
|
|
|
|
known-first-party = ["xonsh", "xontrib", "xompletions", "tests"]
|
|
|
|
|
known-third-party = ["ply", "pytest"]
|
|
|
|
|
|
|
|
|
|
[tool.ruff]
|
|
|
|
|
src = [
|
|
|
|
|
"xonsh", "xontrib", "xompletions", "tests"
|
|
|
|
|
]
|
2024-04-15 17:40:17 +05:30
|
|
|
|
extend-exclude = [
|
2023-04-19 18:29:32 +05:30
|
|
|
|
"docs/",
|
|
|
|
|
"*/ply/",
|
|
|
|
|
"parser*_table.py",
|
|
|
|
|
"completion_parser_table.py",
|
|
|
|
|
"build/",
|
|
|
|
|
"dist/",
|
|
|
|
|
"setup.py",
|
|
|
|
|
".vscode/",
|
|
|
|
|
"feedstock",
|
|
|
|
|
"rever",
|
|
|
|
|
".venv*/",
|
|
|
|
|
".local.out*/",
|
|
|
|
|
]
|
2024-04-15 18:31:23 +05:30
|
|
|
|
line-length = 88
|
2024-04-15 17:40:17 +05:30
|
|
|
|
|
|
|
|
|
[tool.ruff.lint]
|
2023-04-19 18:29:32 +05:30
|
|
|
|
ignore = [
|
|
|
|
|
"D100", # Missing docstring in public module
|
|
|
|
|
"D101", # Missing docstring in public class
|
|
|
|
|
"D102", # Missing docstring in public method
|
|
|
|
|
"D103", # Missing docstring in public function
|
|
|
|
|
"D104", # Missing docstring in public package
|
|
|
|
|
"D105", # Missing docstring in magic method
|
|
|
|
|
"D200", # One-line docstring should fit on one line with quotes
|
|
|
|
|
"D202", # No blank lines allowed after function docstring
|
|
|
|
|
"D205", # 1 blank line required between summary line and description
|
|
|
|
|
"D207", # Docstring is under-indented
|
|
|
|
|
"D208", # Docstring is over-indented
|
|
|
|
|
"D209", # Multi-line docstring closing quotes should be on a separate line
|
|
|
|
|
"D210", # No whitespaces allowed surrounding docstring text
|
|
|
|
|
"D301", # Use r""" if any backslashes in a docstring
|
|
|
|
|
"D400", # First line should end with a period
|
|
|
|
|
"D401", # First line should be in imperative mood
|
|
|
|
|
"D403", # First word of the first line should be properly capitalized
|
|
|
|
|
"D404", # First word of the docstring should not be This
|
|
|
|
|
"D406", # Section name should end with a newline
|
|
|
|
|
"D407", # Missing dashed underline after section
|
|
|
|
|
"D409", # Section underline should be in the line following the section’s name
|
|
|
|
|
"D411", # Missing blank line before section
|
|
|
|
|
"D418", # Function decorated with `@overload` shouldn't contain a docstring
|
|
|
|
|
"E402", # Module level import not at top of file
|
2024-04-15 18:31:23 +05:30
|
|
|
|
"E501", # line length
|
2023-04-19 18:29:32 +05:30
|
|
|
|
"E731", # Do not assign a lambda expression, use a def
|
2024-12-08 14:07:36 +00:00
|
|
|
|
"UP031", # Use format specifiers instead of percent format
|
2023-04-19 18:29:32 +05:30
|
|
|
|
]
|
|
|
|
|
select = [
|
|
|
|
|
"B", # https://beta.ruff.rs/docs/rules/#flake8-bugbear-b
|
|
|
|
|
"D", # https://beta.ruff.rs/docs/rules/#pydocstyle-d
|
|
|
|
|
"E", # https://beta.ruff.rs/docs/rules/#pycodestyle-e-w
|
|
|
|
|
"F", # https://beta.ruff.rs/docs/rules/#pyflakes-f
|
|
|
|
|
"I", # https://beta.ruff.rs/docs/rules/#isort-i
|
|
|
|
|
"T10", # https://beta.ruff.rs/docs/rules/#flake8-debugger-t10
|
2024-04-15 17:40:17 +05:30
|
|
|
|
"TID", # https://docs.astral.sh/ruff/rules/#flake8-tidy-imports-tid
|
2023-04-19 18:29:32 +05:30
|
|
|
|
"YTT", # https://beta.ruff.rs/docs/rules/#flake8-2020-ytt
|
|
|
|
|
"W", # https://beta.ruff.rs/docs/rules/#pycodestyle-e-w
|
|
|
|
|
"UP", # https://beta.ruff.rs/docs/rules/#pyupgrade-up
|
|
|
|
|
]
|
|
|
|
|
|
2024-04-15 17:40:17 +05:30
|
|
|
|
[tool.ruff.lint.pydocstyle]
|
2023-04-19 18:29:32 +05:30
|
|
|
|
convention = "numpy"
|
|
|
|
|
|
2024-04-15 17:40:17 +05:30
|
|
|
|
[tool.ruff.lint.per-file-ignores]
|
2023-04-19 18:29:32 +05:30
|
|
|
|
"xonsh/timings.py" = ["F401"]
|
|
|
|
|
"xonsh/history.py" = ["F821"]
|
2024-06-29 10:28:02 +02:00
|
|
|
|
"xonsh/parsers/lexer.py" = ["E741"]
|
2023-04-19 18:29:32 +05:30
|
|
|
|
"xonsh/parsers/completion_context.py" = ["B018"]
|
2024-07-12 11:11:52 +02:00
|
|
|
|
"xonsh/parsers/tokenize.py" = [
|
2023-04-19 18:29:32 +05:30
|
|
|
|
"F821",
|
|
|
|
|
"F841",
|
|
|
|
|
"B904" # Within an `except` clause, raise exceptions with `raise ... from err`
|
|
|
|
|
]
|
|
|
|
|
"xonsh/pyghooks.py" = ["F821"]
|
|
|
|
|
"tests/test_builtins.py" = [
|
|
|
|
|
"F821",
|
|
|
|
|
"B011",
|
|
|
|
|
]
|
|
|
|
|
"xonsh/built_ins.py" = [
|
|
|
|
|
"F821",
|
|
|
|
|
"E721",
|
|
|
|
|
"E721",
|
|
|
|
|
]
|
|
|
|
|
"xonsh/style_tools.py" = ["F821"]
|
|
|
|
|
"xonsh/xoreutils/*.py" = ["E722"]
|
|
|
|
|
"xonsh/completers/python.py" = ["E722"]
|
2024-06-29 11:58:11 +02:00
|
|
|
|
"xonsh/parsers/ast.py" = ["F401"]
|
2024-06-29 10:56:50 +02:00
|
|
|
|
"xonsh/shells/ptk_shell/__init__.py" = ["E731"]
|
|
|
|
|
"xonsh/shells/readline_shell.py" = ["F401"]
|
2023-04-19 18:29:32 +05:30
|
|
|
|
"xonsh/commands_cache.py" = ["F841"]
|
2024-06-29 10:56:50 +02:00
|
|
|
|
"xonsh/shells/ptk_shell/key_bindings.py" = ["F841"]
|
2023-04-19 18:29:32 +05:30
|
|
|
|
"xonsh/tools.py" = [
|
|
|
|
|
"E731",
|
|
|
|
|
]
|
|
|
|
|
"xonsh/xonfig.py" = ["E731"]
|
|
|
|
|
"xontrib/vox.py" = ["F821"]
|
|
|
|
|
"xonsh/inspectors.py" = ["E722"]
|
2024-06-29 10:28:02 +02:00
|
|
|
|
"xonsh/platform.py" = ["F401"]
|
2023-04-19 18:29:32 +05:30
|
|
|
|
"xonsh/parsers/*.py" = [
|
2024-06-29 11:58:11 +02:00
|
|
|
|
"E741", # E741 Ambiguous variable name
|
2023-04-19 18:29:32 +05:30
|
|
|
|
]
|
|
|
|
|
"tests/test*.py" = [
|
|
|
|
|
"E741", # E741 Ambiguous variable name
|
|
|
|
|
]
|