Skip to content

The subshell does not recognize the path path.  #1486

Open
@haitang002

Description

@haitang002

Here is the use case

cd /root

vi k.sh
#!/bin/ksh
export PATH=.:$PATH:/root/mybin
cur = $(cd /root/mybin; pwd)

ls

cp /bin/ls /root/mybin

This shell script will not be able to execute the last ls; not found ls;
When you comment out the cur line, you can find ls

But there is no problem with this branch: https://github.com/ksh-community/ksh

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions