BKKKPewsey wrote:But we do allow Americans in
That exorcised a hearty chuckle from me. Well done.
The note-worthy information on the script:
That script was slapped together over the course of today and so it carries the generic "use at your own risk" disclaimer. It is all bash except for a single call to sed, to half-parse the xml returned from the REST subsonic api call. It uses special bash filehandles to handle the network connection, but since I am not sure how cross compatible that is (I tested it on gentoo and debian), you can pass the script the '-n' parameter to make it use netcat as the backend, which may or may not be on whatever *nix based system you are using, but will work if the file descriptors do not.
From there, you can run the script one of three ways (or any mixture of them):
1. Just as is. The script is interactive and you can fill the information as needed, when prompted for it.
2. Via the command parameters:
-u - username that will carry out the createUser
-pw - password of said user
-s or -h - hostname of server as domain name or ip
-p - port of that server
-nu - desired username of user to be created
-np - the password of that user
-e - email address of that user
-n - use netcat as the network backend instead of bash file descriptors
3. You can set the variables in the beginning of the script file to whatever you want, and they will stay that way and you won't need to specify them. This could be useful if you are always authenticating under the same username and password all the time, for instance.
note 1: I tried to be nice with the error handling, so hopefully the script will be descriptive enough when (err... I mean *if*) it fails.
note 2: Apologies for the foreign language in the previous post.
note 3: The OP posted two months ago, and has not signed on since then, casting doubt on whither this script will get any use...