Skip to content

Unable to use Process Substitution in User Menu scripts #2227

@mc-butler

Description

@mc-butler

Important

This issue was migrated from Trac:

Origin https://midnight-commander.org/ticket/2227
Reporter ligelowbee (ligelowbee@….com)
Mentions gotar@….pl

I was trying to use process substitution in one of my User Menu scripts but it kept kick out with:
syntax error near unexpected token `('

You can test this by making a menu entry that runs the trivial command:

echo <(ls)

She'll crapout on you nicely

My actual intent was to get a listing diff of all the files in the source and destination directories (including subdirectories) with:

%view diff -u <(find ./ -type f|sort) <(cd %D; find ./ -type f|sort)

I ended up using mktemp files instead of Process Substitution and all is well. Just thought I'd mention the troubles.

Cheers,
Lee

Metadata

Metadata

Assignees

No one assigned

    Labels

    area: coreIssues not related to a specific subsystemprio: lowMinor problem or easily worked aroundver: 4.7.2Reproducible in version 4.7.2

    Type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions