Re: LiveCode post 3.5 on Linux boxes with no display
On 15/09/2011 19:09, Richard Gaskin wrote: Ben Rubinstein wrote: Is there still a way to build a standalone using current LiveCode, that can operate on a Linux box that can only be accessed on the command line? I've been able to build standalones that behave well when run from the command line provided I launch them with the -ui flag and include a quit command after they're done processing. The quit command may not be necessary; I vaguely recall having a CGI hang years ago without that, and so I've been adding it for all CLI usage ever since. Richard, Thanks for the reply. Can you confirm that you can make this work on a Linux machine with no display manager / window manager (I'm not sure of the correct terminology)? As I mentioned, I can make such standalones with 3.5; but built from 4.6.4, it simply hangs on launch even with the -ui flag (without the -ui flag it stops immediately with the message can't open display). Many thanks, Ben ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
Re: LiveCode post 3.5 on Linux boxes with no display
Ben Rubinstein wrote: On 15/09/2011 19:09, Richard Gaskin wrote: I've been able to build standalones that behave well when run from the command line provided I launch them with the -ui flag and include a quit command after they're done processing. The quit command may not be necessary; I vaguely recall having a CGI hang years ago without that, and so I've been adding it for all CLI usage ever since. Richard, Thanks for the reply. Can you confirm that you can make this work on a Linux machine with no display manager / window manager (I'm not sure of the correct terminology)? Better yet, you can test it yourself - Debian 4.0 server: http://fourthworldlabs.com/cgi-bin/tsa.cgi The cgi file includes only what's needed to launch the standalone: #!sa -ui Here's the script in the standalone: on startup put Standalone - Engine version the version into tData put Content-length: len(tData) crcr put tData crcr quit end startup I hope you get this resolved. I was playing around with making a custom interactive shell using read from stdin, and it's a lot of fun to have so much flexibility in a CLI, every bit as capable in terms of interaction as using R, MySQL, or other CLIs. -- Richard Gaskin Fourth World LiveCode training and consulting: http://www.fourthworld.com Webzine for LiveCode developers: http://www.LiveCodeJournal.com LiveCode Journal blog: http://LiveCodejournal.com/blog.irv ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
Re: LiveCode post 3.5 on Linux boxes with no display
Richard- Friday, September 16, 2011, 6:27:34 AM, you wrote: Better yet, you can test it yourself - Debian 4.0 server: ...and that's a debian server with no desktop or xwindows support, right? Just a headless server? -- -Mark Wieder mwie...@ahsoftware.net ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
Re: LiveCode post 3.5 on Linux boxes with no display
Mark Wieder wrote: Richard- Friday, September 16, 2011, 6:27:34 AM, you wrote: Better yet, you can test it yourself - Debian 4.0 server: ...and that's a debian server with no desktop or xwindows support, right? Just a headless server? I believe so; it's at Dreamhost: http://wiki.dreamhost.com/Debian -- Richard Gaskin Fourth World LiveCode training and consulting: http://www.fourthworld.com Webzine for LiveCode developers: http://www.LiveCodeJournal.com LiveCode Journal blog: http://LiveCodejournal.com/blog.irv ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
Re: LiveCode post 3.5 on Linux boxes with no display
On 16/09/2011 14:27, Richard Gaskin wrote: Better yet, you can test it yourself - Debian 4.0 server: You're right - it is working! Hurrah! It appears that the real change is just that '-ui' no longer sets the environment to command line. Unfortunately my test stacks all had the simple code (similar to your one) in openstack but wrapped in a test for the environment = command line. It now returns standalone application, regardless of the -ui flag; so my test stacks weren't doing the stuff they were supposed to, my real stack was attempting to do stuff it shouldn't, and neither was quitting. So that's much better. I've snagged this at RQCC (#9734). In the meantime, is anyone aware of a built-in method, other than the environment to detect running headless? (Obviously if not I can work around it by adding some extra command-line parameters of my own, but that only works if I remember to...). Many thanks for taking the time to set me straight... Ben ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
Re: LiveCode post 3.5 on Linux boxes with no display
Ben- Friday, September 16, 2011, 11:47:08 AM, you wrote: It appears that the real change is just that '-ui' no longer sets the environment to command line. I wasn't aware that it used to set the environment variable. Was that ever documented? -- -Mark Wieder mwie...@ahsoftware.net ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
Re: LiveCode post 3.5 on Linux boxes with no display
On 14/09/2011 16:43, Mark Wieder wrote: Ben- Wednesday, September 14, 2011, 6:01:05 AM, you wrote: I'm catching on late to the removal of the command-line options from Rev 4.0 onwards. Specifically, I have a current application which is sometimes run interactively, but can also be run non-interactively from the command line. To be clear about this, the commandline options have *not* disappeared from post-3.5 LC. I have a commercial app that would have *very* serious problems if this were so. That said, I haven't used the -ui option in some time - I simply hide the stack on preOpenStack and I've got a nice faceless app. Obviously you could pass a commandline option to hide or not, which would let you run the app interactively if desired. Sorry, I misspoke: it's not that you can no longer run LC standalones in command-line mode; but what has I believe gone is the ability to run without attempting to create a graphic user interface, by invoking the app from the command line with the -ui flag. If I've just missed something, I'll be delighted, but as far as I can tell this is the case. I create a simple app which if it finds that the environment = command line does some things and then quits. If I build a standalone with this, using Rev 3.5, and launch it from the command line: - on Mac with no parameters it opens in the normal way, and I can interact with it and quit it using the default menu. - on Mac with -ui nothing appears in the dock or on the screen, it does the requested task and quits. - on a headless Linux box with no parameters I get the message Can't open display - on a headless Linux box with -ui it does the requested task and quits. If I build the same app using LC 4.6.4 - on Mac with no parameters it opens in the normal way, and I can interact with it and quit it using the default menu. - on Mac with -ui the icon bounces in the dock for a long time, and then sticks there; there is no sign of the app working, and it has to be force quit. - on a headless Linux box with no parameters I get the message Can't open display - on a headless Linux box with -ui it hangs. So it would be incorrect to say that the -ui flag has no effect on a standalone built with LC 4.6.4; but it doesn't have the useful effect that it used to. Is there still a way to build a standalone using current LiveCode, that can operate on a Linux box that can only be accessed on the command line? TIA, Ben ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
Re: LiveCode post 3.5 on Linux boxes with no display
Ben Rubinstein wrote: Is there still a way to build a standalone using current LiveCode, that can operate on a Linux box that can only be accessed on the command line? I've been able to build standalones that behave well when run from the command line provided I launch them with the -ui flag and include a quit command after they're done processing. The quit command may not be necessary; I vaguely recall having a CGI hang years ago without that, and so I've been adding it for all CLI usage ever since. -- Richard Gaskin Fourth World LiveCode training and consulting: http://www.fourthworld.com Webzine for LiveCode developers: http://www.LiveCodeJournal.com LiveCode Journal blog: http://LiveCodejournal.com/blog.irv ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
Re: LiveCode post 3.5 on Linux boxes with no display
Ben- Wednesday, September 14, 2011, 6:01:05 AM, you wrote: I'm catching on late to the removal of the command-line options from Rev 4.0 onwards. Specifically, I have a current application which is sometimes run interactively, but can also be run non-interactively from the command line. To be clear about this, the commandline options have *not* disappeared from post-3.5 LC. I have a commercial app that would have *very* serious problems if this were so. That said, I haven't used the -ui option in some time - I simply hide the stack on preOpenStack and I've got a nice faceless app. Obviously you could pass a commandline option to hide or not, which would let you run the app interactively if desired. -- -Mark Wieder mwie...@ahsoftware.net ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode