netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Donald Hunter <donald.hunter@gmail.com>
To: Jan Stancek <jstancek@redhat.com>
Cc: stfomichev@gmail.com,  kuba@kernel.org,  jdamato@fastly.com,
	pabeni@redhat.com,  netdev@vger.kernel.org,
	 linux-kernel@vger.kernel.org
Subject: Re: [PATCH v4 2/4] tools: ynl: add initial pyproject.toml for packaging
Date: Thu, 09 Jan 2025 12:13:14 +0000	[thread overview]
Message-ID: <m2bjwgmbhh.fsf@gmail.com> (raw)
In-Reply-To: <b184b43340f08aef97387bfd7f2b2cd9b015c343.1736343575.git.jstancek@redhat.com> (Jan Stancek's message of "Wed, 8 Jan 2025 14:56:15 +0100")

Jan Stancek <jstancek@redhat.com> writes:

> Add pyproject.toml and define authors, dependencies and
> user-facing scripts. This will be used later by pip to
> install python code.
>
> Signed-off-by: Jan Stancek <jstancek@redhat.com>

The ynl-ethtool script is broken when installed because it hard-codes
spec and schema paths to in-tree locations.  I'd be happy to fix that in
a followup patch, since I have a schema lookup patch in progress.

Reviewed-by: Donald Hunter <donald.hunter@gmail.com>

> ---
>  tools/net/ynl/pyproject.toml | 24 ++++++++++++++++++++++++
>  1 file changed, 24 insertions(+)
>  create mode 100644 tools/net/ynl/pyproject.toml
>
> diff --git a/tools/net/ynl/pyproject.toml b/tools/net/ynl/pyproject.toml
> new file mode 100644
> index 000000000000..a81d8779b0e0
> --- /dev/null
> +++ b/tools/net/ynl/pyproject.toml
> @@ -0,0 +1,24 @@
> +[build-system]
> +requires = ["setuptools>=61.0"]
> +build-backend = "setuptools.build_meta"
> +
> +[project]
> +name = "pyynl"
> +authors = [
> +    {name = "Donald Hunter", email = "donald.hunter@gmail.com"},
> +    {name = "Jakub Kicinski", email = "kuba@kernel.org"},
> +]
> +description = "yaml netlink (ynl)"
> +version = "0.0.1"
> +requires-python = ">=3.9"
> +dependencies = [
> +    "pyyaml==6.*",
> +    "jsonschema==4.*"
> +]
> +
> +[tool.setuptools.packages.find]
> +include = ["pyynl", "pyynl.lib"]
> +
> +[project.scripts]
> +ynl = "pyynl.cli:main"
> +ynl-ethtool = "pyynl.ethtool:main"

  reply	other threads:[~2025-01-09 12:23 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-01-08 13:56 [PATCH v4 0/4] tools: ynl: add install target Jan Stancek
2025-01-08 13:56 ` [PATCH v4 1/4] tools: ynl: move python code to separate sub-directory Jan Stancek
2025-01-08 13:56 ` [PATCH v4 2/4] tools: ynl: add initial pyproject.toml for packaging Jan Stancek
2025-01-09 12:13   ` Donald Hunter [this message]
2025-01-08 13:56 ` [PATCH v4 3/4] tools: ynl: add install target for generated content Jan Stancek
2025-01-09 12:20   ` Donald Hunter
2025-01-08 13:56 ` [PATCH v4 4/4] tools: ynl: add main install target Jan Stancek
2025-01-09 21:00 ` [PATCH v4 0/4] tools: ynl: add " patchwork-bot+netdevbpf

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=m2bjwgmbhh.fsf@gmail.com \
    --to=donald.hunter@gmail.com \
    --cc=jdamato@fastly.com \
    --cc=jstancek@redhat.com \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=stfomichev@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).