Can I pass environment variables like PWD to an iterm trigger?
2
votes
1
answer
296
views
For instance, given the below trigger:
When I double click the captured output, it runs the script:

~/rerun_test.sh
supplying the filename that was matched: \1
.
However, the application I work with does not output the present working directory (PWD) so I need to have it available to me as a variable that I can supply somehow or the other.
For semantic history when you run a command the PWD is \5
for instance:
> Command runs when you activate Semantic History on any filename. Use \1 for filename, \2 for line number, \3 for text before click, \4 for text after click, \5 for pwd. You can also use interpolated string syntax.
Obviously in this context: ~/rerun_test.sh \1 \5
does not work.
How do you supply PWD
to a coprocess
script?
Asked by Kevin Johnson
(121 rep)
May 7, 2020, 11:00 AM
Last activity: May 19, 2025, 01:04 AM
Last activity: May 19, 2025, 01:04 AM