Hi, coreplayer2!
I absolutely agree with you, changing of system files must be avoided as much as possible because of possible side effects, complicating some cases possible in future, and not to put rubbish everywhere. But i faced the case when ~/.X.d scripts execution order matters, and i think i am not alone. And my investigation (see code example above) showed that order is creation order, not alphanumerical. Of course, someone can create scripts according to alphanumerical order, and in this case creation order is identical to alphanumerical. But if no?
And, yes, this additional "sort" will harm those who already achieved desired script execution order with the help of creating them in appropriate sequence, while not naming scripts keeping in mind alphanumerical order like you (
So i modified my own .xsession and want the newbies like me to know about this workout on ~/.X.d scripts, maybe it will help someone else.