Title |
Test
Find
Absolute File Path in UNIX / LINUX
|
Expression |
^((?!.*//.*)(?!.*/ .*)/{1}([^\\(){}:\*\?<>\|\"\'])+\.(csv|jpg|txt|pdf|dat|xls|doc))$ |
Description |
This will match with all absolute file paths in Unix/Linux. The extensions added are csv|jpg|txt|pdf|dat|xls|doc. Can be customized for specific extensions. |
Matches |
/usr/local/data/userdata.xls, /home/userdata.doc, /accounts.txt |
Non-Matches |
//usr/local/data/userdata.xls, //usr/local/,/usr/local/ data/users.txt |
Author |
Rating:
Bijaya Kumar Naik
|
Source |
Created by self |
Your Rating |
|