GNU bug report logs -
#45890
Printf bug GNU coreutils 8.30/8.32
Previous Next
Full log
View this message in rfc822 format
[Message part 1 (text/plain, inline)]
I'm sorry, I found the answer in the FAQ.
So i'ts resolved.
Thanks
‐‐‐‐‐‐‐ Original Message ‐‐‐‐‐‐‐
On Friday, January 15, 2021 12:08 PM, Andrea Dari <andreadari <at> protonmail.com> wrote:
> Hello,
>
> I'm using GNU coreutils 8.30, I found that the printf tool is broken while coding a shell script.
>
> andrea <at> Workstation:~$ printf --version
> bash: printf: --: invalid option
> printf: usage: printf [-v var] format [arguments]
>
> I tried with coreutils 8.32 too with the same error.
>
> PRINTF(1) man page reports the option valid:
>
> NAME
> printf - format and print data
>
> SYNOPSIS
> printf FORMAT [ARGUMENT]...
> printf OPTION
>
> DESCRIPTION
> Print ARGUMENT(s) according to FORMAT, or execute according to OPTION:
>
> --help display this help and exit
>
> --version
> output version information and exit
> ...
>
> the option --help works.
>
> I have another issue with printf, I wanted to print a string that starts with "-" and printf parse it like an option:
>
> andrea <at> Workstation:~$ printf "->"
> bash: printf: ->: invalid option
> printf: usage: printf [-v var] format [arguments]
>
> I'm doing something wrong?
>
> Best Regards,
>
> Andrea Dari
[Message part 2 (text/html, inline)]
This bug report was last modified 4 years and 126 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.