mirror of
https://github.com/GothenburgBitFactory/taskwarrior.git
synced 2025-08-29 17:07:19 +02:00
Enhancement
- Added Path::is_absolute, and corresponding unit tests. - Replaced expandPath and isAbsolutePath call in Config.cpp.
This commit is contained in:
parent
c02cfd594c
commit
e1f3f2355a
4 changed files with 20 additions and 3 deletions
|
@ -121,6 +121,15 @@ bool Path::is_directory () const
|
|||
return false;
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
bool Path::is_absolute () const
|
||||
{
|
||||
if (data.length () && data.substr (0, 1) == "/")
|
||||
return true;
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
bool Path::readable () const
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue