Apache OpenOffice (AOO) Bugzilla – Issue 14437
configmgr: Support operation in a pipe
Last modified: 2008-08-21 16:09:54 UTC
Hi Joerg, long time no hear I've been working on .debs for 1.1 (now that 1.1 runs on Debian :) and am looking at the mechanism for switching user interface language (Issue 10043), and also reconfiguring other small items from scripts. I dug out your mail to -features about configmgr and tried it out, and it works like a charm, thanks! I just have a small request: would it be possible to have a mechanism to read stdin instead of a file? The reason being, I'd like to be able to prepare a template .xcu file and substitute the actual configuration value on the fly, e.g. cat changeLocale.xcu.template | sed 's/%LANGUAGE%/de_DE/' | configmgr.bin - Obviously this can also be done using a temporary file instead so don't treat my request as particularly high priority. It would be nice not to have to rely on a tempfile to avoid race conditions on architectures that do not have a secure way to create tempfiles. BTW, I tried using /dev/stdin as the input file but got an odd error message. Looks like the text should be 'input file' instead of 'output file' ? $ cat setupLocale.xcu | ooconfigimport /dev/stdin configimport.bin - Unhandled exception caught in main: "Cannot open output file "file:///dev/stdin" : the format of the parameters was not valid"
Sounds like a reasonable addition. Alas, the configimport tool uses the osl_file API and an XInputStream on top of that for file access. A solution would require to either provide another XInputStream implementation based on stdio or the possibility to use stdin through the osl file API. From a casual inquiry the latter seems possible, but probably only on UNIX. I don't really like the idea of not offering this on all platforms. The former seems to involve quite a lot of effort and code for this feature. Maybe someone can provide a stdin-XInputStream UNO service. I'll keep the issue around, but don't expect action in the near future. I add the 'needhelp' keyword, so whoever wants to tackle this is welcome to contact me with some ideas on how to proceed.
Handing over @sb: this is a low priority RFE. If issue 21792 is fixed, this one may be fixed automatically or with trivial changes. Set target to OOo PleaseHelp. This is something that could be taken on by an interested community developer looking for a nicely isolated problem.
Now really reassigning
Accepting, just to get the issue away from status NEW.
configimport has been removed through issue 87512
.