Page 1 of 1
Command line import/export
Posted: Thu Mar 11, 2021 1:59 pm
by palfore
I'm trying to automatically import/export different profiles. Is there a way to avoid going through the GUI? Would it be difficult to add the option to import/export via the command line? Commands can already be executed, but I'm not sure if there are any existing flags for different features. I'm thinking something like:
Thanks!
Re: Command line import/export
Posted: Thu Mar 11, 2021 2:40 pm
by RobLatour
Currently, that is not fully possible.
You can however already type the full name (including the extension) of a .p2r file at the cmd prompt to have it imported. However, the GUI does pop-up asking you to confirm you want it imported.
So to be clear, if you have a file called "calculator.p2r", just enter
calculator.p2r
at the command prompt.
I will need to look further into this as a feature request.
Re: Command line import/export
Posted: Fri Mar 12, 2021 7:57 pm
by palfore
Thanks for the information! That does make things easier than what I was doing. It looks like this always starts with the imported commands off. Is there a way to change that, or is there a way to turn all commands on with a single click rather than individually? The master switch can turn them all off, but not on.
Re: Command line import/export
Posted: Fri Mar 12, 2021 9:34 pm
by RobLatour
Starting with imported commands switched off is by design.
The whole idea behind this is that after you import something you will have an opportunity to have a good look at it, and then purposefully turn it on before it starts to run. This to help avoid inadvertently importing and running something that you might not want.
Re: Command line import/export
Posted: Sat Mar 13, 2021 9:06 am
by palfore
I managed to automate almost all of the "profile switching" using Python. The only thing I can't do is enable the commands automatically and if a "profile" has many commands it is quite tedious to manually turn them all on. I know I'm sort of pushing your software (which is awesome btw!) but I'm wondering if you may consider adding a setting (with an appropriate warning to the user) that allows commands to be imported in the on state. Or, to make the manual process easier, a button to switch all commands on, or the ability to highlight multiple commands at once.
Or - and this may be a tiny bug/oversight - but after using F9 (to switch a command on) followed by the down arrow (to move to the next command), the selection goes to the top (master switch) and I have to either click or press the down arrow many times to get back to where I was. If it stayed where it was, then I could at least manually spam F9/downarrow.
I'm trying to think of what would be the easiest solution, and I appreciate your responses and time. Thanks!
Re: Command line import/export
Posted: Sat Mar 13, 2021 11:11 am
by RobLatour
Thanks again for your feedback palfore.
I will look at adding some new options for:
1 - confirmations related to imports
2 - imported cards being turned either on or off by default
Also, thanks for pointing out the bug, I look at fixing it too.
Re: Command line import/export
Posted: Sat Mar 13, 2021 2:06 pm
by RobLatour
I had some time this afternoon so I made and tested the changes described above in a beta copy of the next release of the program.
If you would like an opportunity to try it out and provided additional feedback please let me know at
info@push2run.com
If I don't hear back from you, I will release the update afterI get the help documentation updated as well.
Re: Command line import/export
Posted: Sun Mar 14, 2021 10:27 am
by RobLatour
Thanks again for the feedback palfore, as well as for your review of the beta.
A new version of the program, version 3.5.3, has now been generally released with these changes included.