I am trying to parse the following lines and has to use * (asterisk) as the delimiter.
These lines are in a file, for example tmp.txt and I am using a while loop
Instead of just getting the timestamp, I am getting the timestamp plus what looks like a directory listing of all files, i.e. like a timestamp and echo * of the directory that I am in.
Can anyone please advise how to get around this?
Feeback/advise much appreciated. Thanks in advance.
---------- Post updated at 09:06 PM ---------- Previous update was at 08:42 PM ----------
Note that the strings are supposed to be one long line of strings so tmp.txt should be as below:
NETIO230A-CLI(1) General Commands Manual NETIO230A-CLI(1)NAME
netio230a-cli - CLI to python-netio230a
SYNOPSIS
netio230a-cli [--host HOST] [--port PORT] [--username USERNAME] [--password PASSWORD] -s SOCKET [--on]
DESCRIPTION
netio230a-cli is a command line interface to access the Koukaam NETIO-230A, a cheap but advanced multiple socket with Ethernet control.
Options:
-?
show help message and exit
-h HOST, --host=HOST
Hostname for the device (defaults to the first one found by the discovery in your LAN)
-p PORT, --port=PORT
TCP port (defaults to 1234)
-u USERNAME, --username=USERNAME
username to use for login (defaults to admin)
-w PASSWORD, --password=PASSWORD
password to use for login (will ask if left empty)
-s SOCKET#, --socket=SOCKET#
socketnumber (1-4) to switch on/off
--on
switch on when --on set, off if omitted
AUTHOR
netio230a-cli was written by Philipp Klaus <philipp.l.klaus@web.de>.
This manual page was written by Philipp Huebner <debalance@debian.org>, for the Debian project (and may be used by others).
SEE ALSO netio230a-discover(1), netio230a-gui(1)netio230a-cli 2010-03-09 NETIO230A-CLI(1)