I would like to know if you have a file name > abc (1).bin
or > abc (1).txt
files, how do you read them. The files are with the space and bracket before the .bin
or .txt
extension.
To read the .bin file I have a tool, I can read it easily if I remove the "space and (1)" from the filename. But when I have this space and bracket (1).bin
name, I can not read it.
When I cat
a .txt
file, it works.. but it doesn't work with the .bin
file. Below are the requested tests:
$ cat full_logs-10.2.0.103-2018.02.07\ \(1\).txt
hello,
this is a test.
--------xxxxxxx------xxxxxxx------------xxxxxxx--------
$ LogAnalyzeRebirth -p -x ./ full_logs-2018.02.07\ \(1\).bin
usage: LogAnalyzeRebirth [-h] [-A] [-B] [-C] [-D] [-E] [-F]
[-G GRAPH [GRAPH ...]] [-H] [-I [HISTOGRAM]] [-L]
[-M] [-N] [-P [PDF]] [-R] [-S] [-T] [-U] [-V] [-b]
[-c] [-e] [--moo] [-f] [-g] [-i] [-k] [-l] [-m] [-n]
[-o] [-p PATH] [-q] [-r] [-s] [-t] [-v] [-x EXTRACT]
[-z]
LogAnalyzeRebirth: error: argument -p/--path: expected 1 argument(s)
--------xxxxxxx------xxxxxxx------------xxxxxxx--------
$ LogAnalyzeRebirth.py -p ./ -x "full_logs-10.2.0.103-2018.02.07 (1).bin"
(\ /) (\ /)
( . .) LogAnalyzeRebirth (. . )
c(")(") (")(")o
sh: 1: Syntax error: "(" unexpected
sh: 1: Syntax error: "(" unexpected
sh: 1: Syntax error: "(" unexpected
Extract failed.
LogAnalyzeRebirth can't find full_logs-10.2.0.103-2018.02.07 (1).bin
No such file or directory : ./full_logs-10.2.0.103-2018.02.07 (1)/dmesg
--- Firmware_version ---
No such file or directory : ./full_logs-10.2.0.103-2018.02.07 (1)/version.txt
--------xxxxxxx------xxxxxxx------------xxxxxxx--------
cat "> abc (1).bin"
. – muclux Feb 08 '18 at 07:56cat
was only an example. Whatever you want to do with your.bin
file, put the file name between quotes and the characters used in the name won't matter. – muclux Feb 08 '18 at 08:01-p
. You put-p -x ./...
. – muru Feb 08 '18 at 08:03LogAnalyzeRebirth -x -p ./" full_logs-2018.02.07 (1).bin"
(if there really is a space at the beginning of the file name - if not, omit the space between"
and 'f'.) Possibly after -x you have to insert a value for EXTRACT - see the syntax of your command. – muclux Feb 08 '18 at 08:04LogAnalyzeRebirth.py -p ./ -x "$(printf %q "full_logs-10.2.0.103-2018.02.07 (1).bin")"
, but that won't help if the scripts that this script calls are also broken. – muru Feb 08 '18 at 12:31