help-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: hyphen in a command


From: Greg Wooledge
Subject: Re: hyphen in a command
Date: Tue, 24 Jan 2023 10:59:07 -0500

On Tue, Jan 24, 2023 at 10:51:04AM -0500, Jeffrey Walton wrote:
> On Tue, Jan 24, 2023 at 10:41 AM Jeffrey Martin <dogshed@gmail.com> wrote:
> >
> > I'm using this version which came with Linux Mint:
> > GNU bash, version 5.1.16(1)-release (x86_64-pc-linux-gnu)
> >
> > When I try to run this executable with a hyphen it doesn't like it and
> > tries to run docker instead of docker-compose. It runs it fine when I put
> > in the full path.
> > Is this a bug or a feature?
> > Thanks
> >
> > dogshed@Haili:~$ docker-compose up
> > docker: 'compose' is not a docker command.
> > See 'docker --help'
> >
> > dogshed@Haili:~/Desktop/project$ /usr/bin/docker-compose up
> > Creating network "project_default" with the default driver
> > ERROR: could not find an available, non-overlapping IPv4 address pool among
> > the defaults to assign to the network
> > dogshed@Haili:~/Desktop/project$
> 
> Perform a `command -v docker-compose`. See what's really behind that command.

Better would be "type docker-compose".

unicorn:~$ command -v [[
[[
unicorn:~$ type [[
[[ is a shell keyword

Anyway, I'm betting it's a shell function, which is overriding the binary
found in /usr/bin/.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]