Closed RomelSan closed 3 years ago
Did you set the environment variable COOK
Also by setting the variable directly to the .exe
file.
I am not doing custom settings... Should this work out of the box like version 1.0? v1.0 screenshot
If you set the environment variable and do not restart the device, the variables will not be applied. You must restart the device This worked for me
reference
https://stackoverflow.com/questions/48131439/unable-to-receive-environment-variables-in-golang-and-windows-10
Pointed the COOK var to the folder (restarted and try), then to the exe file (restart and try), finally to the .yaml file and it never worked as intended... Will test on another computer, but for now had to add 2 lines of code (i am not a Go programmer so did the best i could). Added to the code something like this "If there isn't a COOK env var then set the binary path as the variable".
@giteshnxtlvl Hi, can you add that behavior to the code? "If there isn't a COOK env var then set the running binary path as the variable" so it can run right out of the box too. Thanks.
Hi @RomelSan Just delete the env varibale COOK, after that cook.exe will work fine, without need of cook.yaml file.
I mentioned this in Readme before but rn it isn't there, so I will add this again.
@alanEG You can just restart the terminal instead of PC to get modified env variables. Use cmder terminal it is better.
For customization
cook.yaml
cook -config
@giteshnxtlvl I think i found the bug. cook.exe alone won't work
You have a tab in line 49, it should be spaces. Compiled and tested like that and it worked.
Yes, I checked it, it's a bug. Thanks for reporting @RomelSan. Will fix this in a minute.
Bug Fixed
Command:
cook.exe -start first,second -end 2020,2021 start:end
or
cook.exe first,second:2020,2021
Outputs: