Content of file display.props, loaded via .xml
Xvfb Display Properties
Wed Jul 27 18:31:50 CEST 2016
DISPLAY=\:20
XAUTHORITY=/tmp/Xvfb4443942380574278711.Xauthority
Now I want to read this file and get the disply number (20)
String xvfbPropsFile = System.getProperty("display.props");
Pattern p = Pattern.compile("DISPLAY.*([0-9][0-9])",
Pattern.MULTILINE|Pattern.DOTALL);
Matcher m=p.matcher(xvfbPropsFile);
However this match and all the others that I tried do not work, any ideas?