Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

id: Illegal option on macOS #260

Closed
sgade opened this issue Dec 28, 2020 · 7 comments
Closed

id: Illegal option on macOS #260

sgade opened this issue Dec 28, 2020 · 7 comments

Comments

@sgade
Copy link

sgade commented Dec 28, 2020

Bug description

Hello,

I noticed an error message after updating that is displayed every time the prompt is rendered:

id: illegal option -- -
usage: id [user]
       id -A
       id -F [user]
       id -G [-n] [user]
       id -M
       id -P [user]
       id -g [-nr] [user]
       id -p [user]
       id -u [-nr] [user]

The origin seems to be commit a80cb55 which uses flags that are not supported on macOS.
man id lists the following:

NAME
     id -- return user identity

SYNOPSIS
     id [user]
     id -A
     id -F [user]
     id -G [-n] [user]
     id -M
     id -P [user]
     id -g [-nr] [user]
     id -p [user]
     id -u [-nr] [user]

Proposed solution

At the bottom, it even lists the command that should be used in this context. I tested it, it returns the current user's username.

The historic whoami(1) command is equivalent to ``id -un''.

Would be pleased if you could fix the command invocation quickly, as it is very annoying in every single output and even appears after CTRL+L.
If you need any further information or testing, please let me know! Happy to help.

Appreciate your time.

Env

Pure

$ echo $pure_version
3.3.4

Fish

fish --version
fish, version 3.1.2

OS/distribution

lsb_release -a

macOS 11.1 (current as of time of writing)

@edouard-lopez
Copy link
Member

@sgade thanks for the detailed issue. Please update to 3.3.5 as it's been fixed

fisher install rafaelrinaldi/pure@v3.3.5 

@jorgebucaran
Copy link
Contributor

There's no need to specify a tag if this is already in the main branch.

@sgade
Copy link
Author

sgade commented Dec 28, 2020

@edouard-lopez Thanks for your reply.
I updated to 3.4.1 and am still getting the same error message. Could you please check? #259 with the fix is still open, as far as I can tell.

@jorgebucaran
Copy link
Contributor

I think @edouard-lopez meant to downgrade to @3.3.5 until a new release with the fix is out.

@edouard-lopez
Copy link
Member

@sgade stick to 3.3.5, I'm working on #259 to fix thing on macOS

@sgade
Copy link
Author

sgade commented Dec 28, 2020

Alright, will do.

@sgade
Copy link
Author

sgade commented Dec 28, 2020

The fix in 3.4.1 works. 👍 Thank you, @edouard-lopez.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants