Tough question. The “extension” and the app are two different apps from Apple’s point of view, so they have different home directories (~
points to a different place). That changes the behaviour for a lot of things. The extension does not have access to the home directory of the app, and the app does not have access to the home directory of the extension. You will need to experiment, but I would try:
- copy the
.ssh
directory to~shortcuts
(from the app) - in extension, set
SSH_HOME
to~shortcuts/.ssh
(setenv SSH_HOME $SHORTCUTS/.ssh
) - retry the
lg2
commands.