]> xenbits.xensource.com Git - xen.git/commitdiff
automation/console.exp: do not assume expect is always at /usr/bin/
authorRoger Pau Monne <roger.pau@citrix.com>
Mon, 17 Mar 2025 09:31:07 +0000 (10:31 +0100)
committerAndrew Cooper <andrew.cooper3@citrix.com>
Fri, 4 Apr 2025 10:33:55 +0000 (11:33 +0100)
Instead use env to find the location of expect.

Additionally do not use the -f flag, as it's only meaningful when passing
arguments on the command line, which we never do for console.exp.  From the
expect 5.45.4 man page:

> The -f flag prefaces a file from which to read commands from.  The flag
> itself is optional as it is only useful when using the #! notation (see
> above), so  that other arguments may be supplied on the command line.

Signed-off-by: Roger Pau Monné <roger.pau@citrix.com>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
automation/scripts/console.exp

index 310543c33e5e62097a93af84c2d42e67a7c450d9..31ce97b91b639c7c22bddc29a098a45fb1a9fdba 100755 (executable)
@@ -1,4 +1,4 @@
-#!/usr/bin/expect -f
+#!/usr/bin/env expect
 
 if {[info exists env(TEST_TIMEOUT_OVERRIDE)]} {
     set timeout $env(TEST_TIMEOUT_OVERRIDE)