command line: read-only databases and --print-databases

Read-only database are shown with a new "<read-only>" tag.
There is no explicit read/write flag, so a lack of that tag
is no guarantee that a database is really writable. It depends
on the backend whether it checks for write acccess.
This commit is contained in:
Patrick Ohly 2014-04-23 02:19:51 -07:00
parent 237a240a7f
commit 8fae2cd0c9
1 changed files with 3 additions and 0 deletions

View File

@ -2072,6 +2072,9 @@ void Cmdline::listDatabases(SyncSource *source, const string &header)
if (database.m_isDefault) {
out << " <default>";
}
if (database.m_isReadOnly) {
out << " <read-only>";
}
out << endl;
}
}