Mac-Nerd / patchomator

Management script for Installomator.
Apache License 2.0
106 stars 9 forks source link

Issue with --write - bad math expression #18

Closed oweban closed 8 months ago

oweban commented 8 months ago

Saw this mentioned on the MacAdmins Slack and thought I'd give it a go, but have run into problems - followed the steps to get it all up and running, but keep hitting an issue when trying to use the --write option.

It seems to be getting caught up on the first software entry in Installomator, but is dropping the "1" at the beginning of it, somehow.

root@testbedmac ~ # curl -LO https://github.com/Mac-Nerd/patchomator/raw/main/patchomator.sh
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
100 29322  100 29322    0     0  47020      0 --:--:-- --:--:-- --:--:-- 47020
root@testbedmac ~ # chmod a+x patchomator.sh
root@testbedmac ~ # sudo mv patchomator.sh /usr/local/Installomator/
root@testbedmac ~ # cd /usr/local/Installomator 
root@testbedmac Installomator # ./patchomator.sh        
Package labels installed. Last updated 0 days ago.
checkInstallomator:5: no such file or directory: /usr/local/Installomator/Installomator.sh
[ERROR] Installomator was found, but is out of date. You can update it by running 
    sudo /usr/local/Installomator/Installomator.sh installomator 
Patchomator can still discover apps on the system and create a configuration for later use, but will not be able to install or update anything without Installomator.       
Download and install Installomator now? [y/N] y
installer: Package name is 
installer: Upgrading at base path /
installer: Preparing for installation….....
installer: Preparing the disk….....
installer: Preparing ….....
installer: Waiting for other installations to complete….....
installer: Configuring the installation….....
installer:  
#
installer: Validating packages….....
#
installer:  Running installer actions…
installer:  
installer: Finishing the Installation….....
installer:  
#
installer: The software was successfully installed......
installer: The upgrade was successful.
./patchomator.sh:919: bad math expression: operator expected at `password7'
root@testbedmac Installomator # ./patchomator.sh --write
Package labels installed. Last updated 0 days ago.
No existing config file at /Library/Application Support/Patchomator/patchomator.plist. Creating one now.
Initializing Plist...
./patchomator.sh:919: bad math expression: operator expected at `password7'
Mac-Nerd commented 8 months ago

Can you try using either the latest release version (https://github.com/Mac-Nerd/patchomator/releases/download/1.0.8/patchomator-1.0.8.pkg) or the 1.1RC (https://github.com/Mac-Nerd/patchomator/releases/download/1.1RC2/patchomator-1.1.RC2.pkg)

oweban commented 8 months ago

Latest release version worked - sorry about that! I guess I made a poor assumption. It's time for another coffee.

Thanks for being so fast :)