mirror of
https://github.com/Kozea/Radicale.git
synced 2025-04-01 20:27:37 +03:00
add support for cwd+path
This commit is contained in:
parent
fb986ea02e
commit
3eb61a82a6
1 changed files with 4 additions and 0 deletions
|
@ -74,8 +74,12 @@ class StoragePartLock(StorageBase):
|
||||||
else:
|
else:
|
||||||
# Process group is also used to identify child processes
|
# Process group is also used to identify child processes
|
||||||
preexec_fn = os.setpgrp
|
preexec_fn = os.setpgrp
|
||||||
|
# optional argument
|
||||||
|
path = kwargs.get('path', "")
|
||||||
try:
|
try:
|
||||||
command = self._hook % {
|
command = self._hook % {
|
||||||
|
"path": shlex.quote(self._get_collection_root_folder() + path),
|
||||||
|
"cwd": shlex.quote(self._filesystem_folder),
|
||||||
"user": shlex.quote(user or "Anonymous")}
|
"user": shlex.quote(user or "Anonymous")}
|
||||||
except KeyError as e:
|
except KeyError as e:
|
||||||
logger.error("Storage hook contains not supported placeholder %s (skip execution of: %r)" % (e, self._hook))
|
logger.error("Storage hook contains not supported placeholder %s (skip execution of: %r)" % (e, self._hook))
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue