It would be very useful to be able to pass shell commands on the smbsh command line. This has two main advantages: 1) No need to enter an interactive smbsh shell to execute scripts which access windows files 2) Possible to run cron jobs which access windows files and a neat side-effect: You can create shebang scripts which use the smbsh facilities. e.g. trite example: #! /usr/local/samba/bin/smbsh -Uuser%password -- ls -l /smb or semi-interactive $ smbsh -- -c "ls -l /smb" Username: julian Password: total 0 dr-xr-xr-x 2 cmsdev cmsdev 0 Jan 1 1970 KPGB dr-xr-xr-x 2 cmsdev cmsdev 0 Jan 1 1970 PACEGB The attachment contains the proposed code which works for Solaris and I suspect is trivial enough to work for any *nix.
Created attachment 1158 [details] Patch for smbsh to pass command line options to the shell
smbsh has been dropped from the tree due to lack of a maintainer. Thanks for the patch though.