git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: in 2.19.2 t0061-run-command FAILs if . is in $PATH

From
Johannes Schindelin <johannes.schindelin@gmx.de>
Date
Nov 29, 2018, 10:13 UTC
Message-ID
<nycvar.QRO.7.76.6.1811291112460.41@tvgsbejvaqbjf.bet>
In-Reply-To
<xmqqpnuor6qs.fsf@gitster-ct.c.googlers.com>
Hi Merijn and Junio,
On Thu, 29 Nov 2018, Junio C Hamano wrote:
Show 19 quoted lines
> Johannes Schindelin <Johannes.Schindelin@gmx.de> writes:
> 
> > -test_expect_success 'run_command is restricted to PATH' '
> > +test_lazy_prereq DOT_IN_PATH '
> > +	case ":$PATH:" in
> > +	*:.:*) true;;
> > +	*) false;;
> > +	esac
> > +'
> 
> An empty element in the colon-separated list also serves as an
> instruction to pick up executable from $cwd, so
> 
> 	case ":$PATH:" in
> 	*:.:** | *::*) true ;;
> 	*) false ;;
> 	esac
> 
> perhaps.
Good point.

Merijn, please be sure to squash this fix in before you submit the final thing.

Thanks, Johannes

Show 13 quoted lines
> 
> > +test_expect_success !DOT_IN_PATH 'run_command is restricted to PATH' '
> >  	write_script should-not-run <<-\EOF &&
> >  	echo yikes
> >  	EOF
> > -- snap --
> >
> > If so, can you please provide a commit message for it (you can add my
> > Signed-off-by: line and your Tested-by: line).
> >
> > Thanks,
> > Johannes
> 
Previous: Junio C Hamano
Message 4 of 4 in “in 2.19.2 t0061-run-command FAILs if . is in $PATH”
  1. H.Merijn BrandNov 28, 2018
  2. Johannes SchindelinNov 28, 2018
  3. Junio C HamanoNov 29, 2018
  4. Johannes SchindelinNov 29, 2018

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.