On Mon, Feb 1, 2016 at 7:00 PM, Scott Kostyshak <skost...@lyx.org> wrote: >> >> >> >> >> >> >> >> I am trying to import the file y.lyx (attached) into the file x.lyx >> >> >> >> (also attached) with the following command: >> >> >> >> >> >> >> >> lyx x.lyx -batch -i lyx y.lyx >> >> >> >> >> >> >> >> Unfortunately, y.lyx is not imported into x.lyx. Any ideas? >> >> >> > >> >> >> > Dear Paul, >> >> >> > >> >> >> > I believe that the command-line import is the analogy of the GUI >> >> >> > File > >> >> >> > Import. Further, I think that if you import a document, I think it >> >> >> > becomes its own .lyx file. What is the GUI equivalent of what you >> >> >> > want >> >> >> > to do? Perhaps Insert > File > LyX Document? >> >> >> > >> >> >> > After we figure out the GUI equivalent, perhaps someone will have an >> >> >> > idea for how to do it on the command line. >> >> >> >> >> >> Thanks, Scott, for your reply. >> >> >> >> >> >> Indeed, I would like to do with a command what one gets with >> >> >> >> >> >> GUI -> Insert -> File -> LyX Document. >> >> > >> >> > OK. And where in your document would you like that command to be issued? >> >> >> >> I would like to have y.lyx inserted at the end of document x.lyx. Thanks, >> >> Scott. >> > >> > As a start, it would be good to figure out which underlying LyX LFUNs >> > replicate this GUI behavior. Are you familiar with how to do that? >> >> No, Scott, I am not familiar at all with LyX LFUNs. > > OK, the first step then is to be familiar with LFUNs. Then we can try to > automate things. LFUNs are how LyX performs actions. Usually they are > behind the scenes, but you can also use LyX's "scripting language" to > replicate behavior. See here for a general description (and follow the > links in there): > https://wiki.lyx.org/LyX/Mini-buffer > See also Help > LyX functions > Finally, to figure out which LFUNs the GUI is running, see here: > http://tex.stackexchange.com/questions/208510/lyx-commands-to-insert-wysiwyg-horizontal-line-for-keyboard-shortcut/208531#208531 > > Let us know once you are able to figure out the command-sequence to put > the cursor at the end of the document and insert the LyX file. Can you > get it to work how you want in the minibuffer? > > Once you figure that out, then you can try it on the command line. See > lyx --help, in particular the -x option. > > If you get lost at any of the above steps, please feel free to ask us > for help. Be clear with what you have tried so far and where exactly you > get stuck
Thanks, Scott, for the directions you have offered me. I did not imagine that would be so complicated, as the documentation only refers using the option -i lyx filename.lyx in the command. Paul