netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Yujie Liu <yujie.liu@intel.com>
To: Guillaume Nault <gnault@redhat.com>, Hangbin Liu <liuhangbin@gmail.com>
Cc: <netdev@vger.kernel.org>, Paolo Abeni <pabeni@redhat.com>,
	David Ahern <dsahern@kernel.org>,
	<linux-kselftest@vger.kernel.org>, <linux-kernel@vger.kernel.org>,
	<lkp@intel.com>, kernel test robot <oliver.sang@intel.com>
Subject: Re: [PATCH v2 net-next] selftests/net: change shebang to bash to support "source"
Date: Tue, 2 Jan 2024 13:51:56 +0800	[thread overview]
Message-ID: <ZZOkfPgs6T3ujpJo@yujie-X299> (raw)
In-Reply-To: <ZZFbxyQeHgf3UQrN@debian>

On Sun, Dec 31, 2023 at 01:17:11PM +0100, Guillaume Nault wrote:
> On Fri, Dec 29, 2023 at 09:19:31PM +0800, Yujie Liu wrote:
> > The patch set [1] added a general lib.sh in net selftests, and converted
> > several test scripts to source the lib.sh.
> > 
> > unicast_extensions.sh (converted in [1]) and pmtu.sh (converted in [2])
> > have a /bin/sh shebang which may point to various shells in different
> > distributions, but "source" is only available in some of them. For
> > example, "source" is a built-it function in bash, but it cannot be
> > used in dash.
> > 
> > Refer to other scripts that were converted together, simply change the
> > shebang to bash to fix the following issues when the default /bin/sh
> > points to other shells.
> 
> Looks like it'd be simpler to just replace the "source" commands with
> "." and leave the shebang as is (unless there are other bash-specific
> constructs in these scripts of course).
> 
> Generally speaking, I think we should avoid madating a specific shell,
> unless that really simplifies the test script (which is not the case
> here).

Hi Guillaume,

Thanks for the comments. As this is related with a large patch series from
Hangbin, and other scripts use "source" during the conversion, so we may
need some input from Hangbin.

Hi Hangbin,

Could you please share your comments on this? Would you like to replace
"source" with "." for these two specific scripts as Guillaume suggested,
or change the shebang from "sh" to "bash"?

Best Regards,
Yujie

  reply	other threads:[~2024-01-02  5:56 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-12-29 13:19 [PATCH v2 net-next] selftests/net: change shebang to bash to support "source" Yujie Liu
2023-12-29 15:19 ` Przemek Kitszel
2023-12-30  6:20 ` Hangbin Liu
2023-12-30  6:30 ` Muhammad Usama Anjum
2023-12-31 12:17 ` Guillaume Nault
2024-01-02  5:51   ` Yujie Liu [this message]
2024-01-02  6:51     ` Hangbin Liu
2024-01-02  8:20   ` Yujie Liu
2024-01-02 11:32     ` Guillaume Nault
2023-12-31 16:27 ` Guillaume Nault
2024-01-04  1:10 ` 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=ZZOkfPgs6T3ujpJo@yujie-X299 \
    --to=yujie.liu@intel.com \
    --cc=dsahern@kernel.org \
    --cc=gnault@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-kselftest@vger.kernel.org \
    --cc=liuhangbin@gmail.com \
    --cc=lkp@intel.com \
    --cc=netdev@vger.kernel.org \
    --cc=oliver.sang@intel.com \
    --cc=pabeni@redhat.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).