On 5/8/24 7:09 AM, Matheus Afonso Martins Moreira wrote:
In these discussions we've managed to
discover at least two *concrete* reasons
why it should actually be a builtin.
- It can avoid touching PATH.
Pure shell import cannot.
- It's compatible with restricted shells.
Most module managers resolve the path
and pass in absolute file names, as you noted.
Neither of these requires a new builtin command. They require changes to
the shell, since they differ from existing functionality, but those changes
don't have to take the form of a builtin.
The number of lines being 203 is definitely large.
Definitely large? I don't know about that.
I even split it up into logical changes.
It takes less than a dozen lines of code to implement BASH_SOURCE_PATH.
--
``The lyf so short, the craft so long to lerne.'' - Chaucer
``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU c...@case.edu http://tiswww.cwru.edu/~chet/