Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
Hello monks
I can read the UUID from Terminal with the following:
ioreg -d2 -c IOPlatformExpertDevice | awk -F\" '/IOPlatformUUID/{print $(NF-1)}'I need to do the same from a Perl script. My solution is not working:
$UUID = (`ioreg -d2 -c IOPlatformExpertDevice | awk -F\" '/IOP +latformUUID/{print $(NF-1)}'`); print $UUID;
It is complaining with sh: -c: line 0: unexpected EOF while looking for matching `"'. Why?
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Read UUID on macOS from script
by haukex (Archbishop) on Mar 30, 2022 at 10:31 UTC | |
by stevieb (Canon) on Mar 30, 2022 at 21:01 UTC | |
|
Re: Read UUID on macOS from script
by hippo (Archbishop) on Mar 30, 2022 at 10:24 UTC |