I have now implemented the flag -x in the master.
pike -x foo
will run the program which Tools.Standalone.foo resolvs to using the module system. rsif has been adapted to use this system, and I made a small "pv" as well. Now for `pike -x module'...
What would that be used for? Shat is Tools.Standalone? Could you please elaborate.
/ Mikael Brandström (ogg! ogg! ogg!)
Previous text:
2002-09-05 17:51: Subject: -x
I have now implemented the flag -x in the master.
pike -x foo
will run the program which Tools.Standalone.foo resolvs to using the module system. rsif has been adapted to use this system, and I made a small "pv" as well. Now for `pike -x module'...
/ Marcus Comstedt (ACROSS) (Hail Ilpalazzo!)
It's used for invoking tools (such as rsif, pv, pike-module etc) from a standard location. The module Tools.Standalone is that standard location.
/ Marcus Comstedt (ACROSS) (Hail Ilpalazzo!)
Previous text:
2002-09-05 18:24: Subject: -x
What would that be used for? Shat is Tools.Standalone? Could you please elaborate.
/ Mikael Brandström (ogg! ogg! ogg!)
Thanks. That's useful. :-)
/ Mikael Brandström (ogg! ogg! ogg!)
Previous text:
2002-09-06 00:31: Subject: -x
It's used for invoking tools (such as rsif, pv, pike-module etc) from a standard location. The module Tools.Standalone is that standard location.
/ Marcus Comstedt (ACROSS) (Hail Ilpalazzo!)
Silly idea: Use Tools.Standalone[basename(argv[0])] (allows symlinks to pike to work as rsif, hilfe, etc)
/ Fredrik (Naranek) Hubinette (Real Build Master)
Previous text:
2002-09-05 17:51: Subject: -x
I have now implemented the flag -x in the master.
pike -x foo
will run the program which Tools.Standalone.foo resolvs to using the module system. rsif has been adapted to use this system, and I made a small "pv" as well. Now for `pike -x module'...
/ Marcus Comstedt (ACROSS) (Hail Ilpalazzo!)
Hm. Interresting idea. But when would that be used? If you make a symlink "rsif" that points to pike, and invoke it as "rsif foo.pike bar.pike Makefile" then this will look like a pretty normal invocation to the master, so how would it know it was supposed to do Tools.Standalone[basename(argv[0])] in this case?
At any rate, it's simple to make a short script (or alias) instead of a symlink if you want. rsif now looks like this:
#! /bin/sh exec pike -x rsif "$@"
Granted, a symlink would be even easier to make. But I don't think it would provide enough information to the master. Am I wrong?
/ Marcus Comstedt (ACROSS) (Hail Ilpalazzo!)
Previous text:
2002-09-06 00:53: Subject: -x
Silly idea: Use Tools.Standalone[basename(argv[0])] (allows symlinks to pike to work as rsif, hilfe, etc)
/ Fredrik (Naranek) Hubinette (Real Build Master)
Pike could look at the file, see if it's a symlink to itself and... :-)
/ David Hedbor (I live in interesting times)
Previous text:
2002-09-06 01:06: Subject: -x
Hm. Interresting idea. But when would that be used? If you make a symlink "rsif" that points to pike, and invoke it as "rsif foo.pike bar.pike Makefile" then this will look like a pretty normal invocation to the master, so how would it know it was supposed to do Tools.Standalone[basename(argv[0])] in this case?
At any rate, it's simple to make a short script (or alias) instead of a symlink if you want. rsif now looks like this:
#! /bin/sh exec pike -x rsif "$@"
Granted, a symlink would be even easier to make. But I don't think it would provide enough information to the master. Am I wrong?
/ Marcus Comstedt (ACROSS) (Hail Ilpalazzo!)
Wouldn't work. What if I did a symlink 'pike7.3.53' pointing to a particular pike binary? I wouldn't want that to try to execute Tools.Standalone["pike7.3.53"]. Besides, the normal "pike" command is also installed as a symlink, isn't it?
/ Marcus Comstedt (ACROSS) (Hail Ilpalazzo!)
Previous text:
2002-09-06 01:21: Subject: -x
Pike could look at the file, see if it's a symlink to itself and... :-)
/ David Hedbor (I live in interesting times)
On Fri, Sep 06, 2002 at 01:25:05AM +0200, Marcus Comstedt (ACROSS) (Hail Ilpalazzo!) @ Pike (-) developers forum wrote:
Wouldn't work. What if I did a symlink 'pike7.3.53' pointing to a particular pike binary? I wouldn't want that to try to execute Tools.Standalone["pike7.3.53"].
why not? Tools.Standalone["pike7.3.53"] is unlikely to exist, the default should be to simply run pike as is if nothing is found in Tools.Standalone.
besides, this could be an interresting way to invoke compatibility mode.
greetings, martin.
why not? Tools.Standalone["pike7.3.53"] is unlikely to exist,
True.
the default should be to simply run pike as is if nothing is found in Tools.Standalone.
Sooner or later this will clash with something someone uses. I currently have pikes called "aido", "roxen", "pike13", "aido-server", "snarf", "easyget" and "xeno".
besides, this could be an interresting way to invoke compatibility mode.
No thank you. To much unobvious magic.
/ Peter Bortas
Previous text:
2002-09-06 10:26: Subject: Re: -x
On Fri, Sep 06, 2002 at 01:25:05AM +0200, Marcus Comstedt (ACROSS) (Hail Ilpalazzo!) @ Pike (-) developers forum wrote:
Wouldn't work. What if I did a symlink 'pike7.3.53' pointing to a particular pike binary? I wouldn't want that to try to execute Tools.Standalone["pike7.3.53"].
why not? Tools.Standalone["pike7.3.53"] is unlikely to exist, the default should be to simply run pike as is if nothing is found in Tools.Standalone.
besides, this could be an interresting way to invoke compatibility mode.
greetings, martin.
/ Brevbäraren
Apart from being slightly inefficient to have to poll Tools.Standalone for _every_ invocation of pike, it's not robust enough. For starters, consider the case where I misspell my symlink:
ln -s pike rsig ./rsig dangerous.pike safe.pike Makefile ^ tab completion
Instead of complaining that the tool "rsig" doesn't exist, this would actually start interpreting "dangerous.pike", which is not at all what I wanted.
Secondly, think about Peters case where he has a symlink called for example "aido", which simply points to a pike suitable for running aido with. If some future release were to add a Tools.Standalone.aido, this would cause his aido invocations to do something else compeltely, despite that he hasn't changed them.
/ Marcus Comstedt (ACROSS) (Hail Ilpalazzo!)
Previous text:
2002-09-06 10:26: Subject: Re: -x
On Fri, Sep 06, 2002 at 01:25:05AM +0200, Marcus Comstedt (ACROSS) (Hail Ilpalazzo!) @ Pike (-) developers forum wrote:
Wouldn't work. What if I did a symlink 'pike7.3.53' pointing to a particular pike binary? I wouldn't want that to try to execute Tools.Standalone["pike7.3.53"].
why not? Tools.Standalone["pike7.3.53"] is unlikely to exist, the default should be to simply run pike as is if nothing is found in Tools.Standalone.
besides, this could be an interresting way to invoke compatibility mode.
greetings, martin.
/ Brevbäraren
pike-devel@lists.lysator.liu.se