#include <StringConstants.au3> ; to declare the Constants of StringRegExp
#include <Array.au3> ; UDF needed for _ArrayDisplay and _ArrayConcatenate
Local $sRegex = "(?m)(?<=sda1)\s+(?|(\d+.?\d+)[G,M.L,%]?)\s+(?|(\d+.?\d+)[G,M.L,%]?)\s+(?|(\d+.?\d+)[G,M.L,%]?)\s+(\d+)%"
Local $sString = "Filesystem Size Used Avail Use% Mounted on" & @CRLF & _
"udev 3.8G 0 3.8G 0% /dev" & @CRLF & _
"tmpfs 806M 5.3M 800M 1% /run" & @CRLF & _
"/dev/mmcblk0p2 235G 59G 164G 27% /" & @CRLF & _
"tmpfs 4.0G 0 4.0G 0% /dev/shm" & @CRLF & _
"tmpfs 5.0M 48K 5.0M 1% /run/lock" & @CRLF & _
"/dev/mmcblk0p1 510M 63M 448M 13% /boot/firmware" & @CRLF & _
"/dev/sda1 137.8G 299.88G 127G 3% /media/usbplatte" & @CRLF & _
"tmpfs 806M 0 806M 0% /run/user/1000" & @CRLF & _
"" & @CRLF & _
"/dev/sda1 139752 2662 129920 3% /media/usbplatte" & @CRLF & _
""
Local $aArray = StringRegExp($sString, $sRegex, $STR_REGEXPARRAYGLOBALFULLMATCH)
Local $aFullArray[0]
For $i = 0 To UBound($aArray) -1
_ArrayConcatenate($aFullArray, $aArray[$i])
Next
$aArray = $aFullArray
; Present the entire match result
_ArrayDisplay($aArray, "Result")
Please keep in mind that these code samples are automatically generated and are not guaranteed to work. If you find any syntax errors, feel free to submit a bug report. For a full regex reference for AutoIt, please visit: https://www.autoitscript.com/autoit3/docs/functions/StringRegExp.htm