smbinfo: update notify subcommand
Subsystems (2)
ChenXiaoSong
reviewerPATCH 1/1 smbinfo: update notify subcommand
From: ChenXiaoSong <[email protected]>
Add the notify subcommand to bash-completion.
Fix the following warning:
./smbinfo:963: SyntaxWarning: 'return' in a 'finally' block
return False
Signed-off-by ChenXiaoSong <[email protected]>
--- bash-completion/smbinfo | 5 +++-- smbinfo | 3 +-- 2 files changed, 4 insertions(+), 4 deletions(-)
bash-completion/smbinfo +3 -2
@@ -24,7 +24,8 @@ smb_info() quota secdesc keys - gettconinfo" + gettconinfo + notify" case $prev in '-v'|'-h') return 0
@@ -33,7 +34,7 @@ smb_info() 'filefsfullsizeinfo'|'fileinternalinfo'|'filemodeinfo'|'filepositioninfo'|\ 'filestandardinfo'|'filestreaminfo'|'filecompressioninfo'|'fsctl-getobjid'|\ 'getcompression'|'setcompression'|'list-snapshots'|'quota'|'secdesc'|'keys'|\ - 'gettconinfo') + 'gettconinfo'|'notify') local IFS=$'\n' compopt -o filenames COMPREPLY=( $(compgen -f -o dirnames -- ${cur:-""}) )
smbinfo +1 -2
@@ -306,7 +306,7 @@ def main(): sap.add_argument("file") sap.set_defaults(func=cmd_gettconinfo) - sap = subp.add_parser("notify", help="Query a directory for change notifications") + sap = subp.add_parser("notify", help="Query a directory for change notifications. Press Ctrl+C to exit.") sap.add_argument("file") sap.set_defaults(func=cmd_notify)
@@ -960,7 +960,6 @@ def cmd_notify(args): pass finally: os.close(fd) - return False def notify_thread(fd): fmt = "<IBI"
Signature · 1 line
2.54.0
added to smb3-utils for-next
Quoted 63 lines · ChenXiaoSong
From: ChenXiaoSong <[email protected]>
Add the
notifysubcommand to bash-completion.Fix the following warning:
./smbinfo:963: SyntaxWarning: 'return' in a 'finally' block
return FalseSigned-off-by ChenXiaoSong <[email protected]>--- bash-completion/smbinfo | 5 +++-- smbinfo | 3 +-- 2 files changed, 4 insertions(+), 4 deletions(-)bash-completion/smbinfo +3
-2@@ -24,7 +24,8 @@ smb_info() quota secdesc keys - gettconinfo" + gettconinfo + notify" case $prev in '-v'|'-h') return 0@@ -33,7 +34,7 @@ smb_info() 'filefsfullsizeinfo'|'fileinternalinfo'|'filemodeinfo'|'filepositioninfo'|\ 'filestandardinfo'|'filestreaminfo'|'filecompressioninfo'|'fsctl-getobjid'|\ 'getcompression'|'setcompression'|'list-snapshots'|'quota'|'secdesc'|'keys'|\ - 'gettconinfo') + 'gettconinfo'|'notify') local IFS=$'\n' compopt -o filenames COMPREPLY=( $(compgen -f -o dirnames -- ${cur:-""}) )smbinfo +1
-3@@ -306,7 +306,7 @@ def main(): sap.add_argument("file") sap.set_defaults(func=cmd_gettconinfo) - sap = subp.add_parser("notify", help="Query a directory for change notifications") + sap = subp.add_parser("notify", help="Query a directory for change notifications. Press Ctrl+C to exit.") sap.add_argument("file") sap.set_defaults(func=cmd_notify)@@ -960,7 +960,6 @@ def cmd_notify(args): pass finally: os.close(fd) - return False def notify_thread(fd): fmt = "<IBI" --2.54.0
Signature · 3 lines
Thanks, Steve