i really like to optimise code(or see it being getting better)
i just tested the way you get the resolution and it does not work properly on multimonitor systems
i had my reasons to write the code the way i did it...
try to get the res out of this xrandr -q output... but without using "current H x W" because that would force you to a) use all monitors or B) disable all but one
Screen 0: minimum 320 x 200, current 3080 x 1050, maximum 3080 x 3080
DFP1 connected 1680x1050+1400+0 (normal left inverted right x axis y axis) 474mm x 296mm
1680x1050 59.9*+
1152x648 60.0 +
1600x1200 60.0
1400x1050 60.0
1280x1024 75.0 60.0
1440x900 59.9
1280x960 75.0 60.0
1280x800 75.0 60.0
1152x864 75.0 60.0
1280x768 74.9 59.9
1280x720 60.0
1024x768 75.0 70.1 60.0
800x600 72.2 75.0 70.0 60.3 56.2
720x480 60.0
640x480 75.0 72.8 60.0
DFP2 disconnected (normal left inverted right x axis y axis)
CRT1 connected 1400x1050+0+0 (normal left inverted right x axis y axis) 408mm x 306mm
1400x1050 60.0*+
1280x1024 75.0 60.0
1280x960 75.0 60.0
1280x800 75.0 60.0
1152x864 75.0 60.0
1280x768 74.9 59.9
1280x720 60.0
1024x768 75.0 70.1 60.0
800x600 72.2 75.0 70.0 60.3 56.2
720x480 60.0
640x480 75.0 72.8 60.0
CRT2 disconnected (normal left inverted right x axis y axis)
TV disconnected (normal left inverted right x axis y axis)
CV disconnected (normal left inverted right x axis y axis)
You were testing too many time, might as well just test once and have the fallback -ie why bother testing for 32bit, 64bit and then fallback to 32bit when you could just test for 64bit and then default to 32bit.
now, my script outputs a warning but maybe its useless... but can you prove that the output of uname -m for a 6 bit OS is always x86_64? because f the issues with 32 bit systems i used the arch of init prcess
I really don't like how the version number is being fetched, especially via parsing the output of ls I am thinking of a better way plus a bit more future-proof but without any nice way to determine version number (I tried string over the binary) might have to rely on the cfg filename
yeah thats right, i don't like it either, but for now its almost the only possible solution(you could grep it out of the dir name, but that can be changed by the user)
why bother distinguing between multimon, just get it to loop through all the results.
because i wanted the possibility to use all monitors or just one without the need to disable all the others
when you set the variables at the beginning of my script, most the tests are skipped