Cannot use 'set -s' in bjorne
Project: | JNode Shell |
Component: | Code |
Category: | bug report |
Priority: | normal |
Assigned: | Stephen Crawley |
Status: | closed |
Jump to:
Description
This problem was noted by cluster on another issue.
The root problem is that we've overloaded 'set'. There is a jnode command called 'set' with the following syntax:
set <name> [ <value> ] # set or remove System property set -s <name> [ <value> ] # set or remove Shell property
but in bjorne there is a POSIX builtin with the syntax
set [ <opts> ] <name>=<value> # set a Shell variable
When you are using bjorne, the latter syntax masks the former and ... you cannot change jnode.interpreter.
- Login to post comments
#1
I've checked in a workaround which is to make 'propset' an alias for classic JNode 'set'. But I don't think this is the complete answer. IMO, it is a bad idea to have conflicting syntaxes for a core command. Here are some possible ways to address this:
I prefer the first solution. It is less work and more robust than the second solution, and the third solution assumes that we want to entirely get rid of the primitive interpreters in the long run.
If people have other ideas / views, please comment.
#2
I say change the name. It's a namespace conflict.
#3
`propset` is in, and there's been no objections, can we mark this fixed?
#4
OK. I'll delete the 'set' alias and mark this as fixed.
#5
Manually closed.