Closed mundya closed 9 years ago
So, I have rather mixed feelings about this idea. I also generally tend to use the same board and would certainly benefit from this behaviour, and I'm sure this feeling is shared. My worries are twofold: obviously this introduces some level of complexity to the implementation but also may lead to the temptation to defer many more options to such a config file. What are your thoughts?
Regarding implementation it seems like we have a couple of options: we could make this specific to the command-line tools or we could make it influence the standard library.
The standard library approach may well be cleaner but runs the risk of making life more difficult for users who must inevitably set up these config files or suffer under poorly designed libraries which presume all options will come from the config files. Another downside is that end-users will end up wondering why they're fiddling around with this 'rig' thing when what they want is application X. (Great technology is invisible etc. etc.)
The other approach, of course, has the disadvantage that the rig command-line tools are far enough away from being a complete set that it is a "lot" of effort to set up for a relatively limited set of use cases.
I realise these are relatively petty concerns about a fairly minor feature but I suspect it is a feature which, if introduced, would later grow in scope (for better or for worse) and so as ever I'd really like to see it done right or not at all. On that theme, it would be worth thinking about other possible ways to tackle the inconvenience of having to specify machines in rig-using programmes generally. A not-so-far-away future will very likely bring some system to allow the sharing of a pool of SpiNNaker machines and this has the potential for making the situation rather more confusing so, again, it would be good to see if we can think of something which will work for that.
Post a brief offline discussion we have decided to hold back on this change until we can find a nicer solution. It was emphasised that this is clearly something which is desireable to work on at some point, though.
I find I rarely use Rig's command-line programs with more than 1 SpiNNaker machine, it'd be nice if I could store some of the arguments I typically pass to every call.
If I had a config file like:
All commands would use
DEFAULT
if I neglected to supply the arguments, so:rig-boot
would be equivalent torig-boot 192.168.1.1 3
rig-power
would berig-power 192.168.1.0
rig-info
would berig-info 192.168.1.1
If I supplied an alias name then those parameters would be used, e.g.,
rig-boot small
would use the supplied alias, i.e., it would be equivalent torig-boot 192.168.240.243 2 2
Any thoughts on this?