-
Notifications
You must be signed in to change notification settings - Fork 13
I'd like to start this discussion to make sure we think about this correctly before attempting to develop it.
Goal
Have the script run on various accounts of the same email, taking into consideration configs and account-infos for each account. Give users as much choice and freedom as possible.
Brainstorming
How? Probably with a mix of new config.ini variables and flags.
I'm thinking of a config.ini variable in the Player section called accountNumber=0 which dictates which account this config.ini file is assigned to. The default value is 0, which would mean the script would not attempt to change accounts. If, however, accountNumber is greater than 0, the script should attempt to click on the appropriate account inside the "Select Server" setting before executing, where the top one is 1 and the bottom one 6. We'll probably have a maximum of 6 accounts by the looks of it, as more require scrolling. And who even has more than 6 accounts to run the script on... If you do, you're probably wanting to sell the account later and I don't like that anyways.
Regarding flags, I'm guessing we'll have to use those to let the script know which config files to use. But various questions arise:
- What is the best way (UX-wise) to let users make use of multi-accounts?
- How can we make sure that all the necessary
config.inifiles get sent to the emulator, while also relaunching the same script with anotherconfig.ini?
And I don't really have an answer to be honest.
- Maybe a flag that you could repeat various times (
./deploy.sh -a configAcc1.ini -a configAcc2.ini ...) - Maybe a flag that has various inputs that we have to filter then (
./deploy.sh -a "configAcc1.ini,configAcc2.ini") - Maybe a flag that has a number of accounts and we force users to name their config files in a specifically numbered way (
./deploy.sh -a 3and there are threeconfigAcc[1|2|3]files) - Other options...?
Considerations
- What happens for default values? Ideally nothing special, the script simply runs as if it's the main account, basically like it's running now.
All reactions
Replies: 2 comments 2 replies
First part sounds great, with accountNumber=0 maintaining current behaviour and 1-6 initiating the account checks before running tasks, I think its better to store those in the config file than a launch parameter as my accounts need different config files already.
For the second I was going to run them separately, but maybe we can have a variable at the end of config.ini RunNextConfig=configname.ini that will run that config once current tasks have been successfully completed? or modify the current endAt= setting to accept config files
All reactions
Uuh, I really like that idea! We could definitely make use of something like that! Nice point to keep in mind. The only downside is that you may easily get lost inside all of these config files where you gotta search for what the next step. Can be quite annoying to search for such a long chain of events per file.
Personally, I always like to go for the one that's the least difficult for users. So, typing in long names as flags is not the best idea. Which means:
Ideas that are left are either the script automatically checking if there are configs with specific names (config-acc1.ini, acc2.ini, etc...), or your idea.
I do think that I enjoy the specific names for configs more now that I'm thinking about it. I think it'll be easier for users to use that. Though I still want to make think twice about this and make sure.
And of course, more ideas are definitely welcome!
All reactions
Maybe the sequential running can be planned for the future? My priority currently is to get basic functionality for my configuration (cron-ing accounts to run daily tasks at reset) so I can move to the main branch. I agree with specific names though, I have main account, SG account and test server account so I'd rather have them named than remember them by acc1-acc2 etc
All reactions
Well, I don't mind planning sequential running for the future. I just wonder how we're supposed to implement it without it? We could as a very basic feature, implement the following:
config.inifiles have theaccountNumbervariable that works as explained before- You can use the
-iflag to specify which config to use
If I understand you correctly, this would be enough for you to programmatically run all your accounts. You'd need to create one config file per account, and simply run the script with whichever config file you want.
Would that work for you?