Skip to content

feat: use process-file to allow eval-buffer to work over tramp#34

Open
DinoChiesa wants to merge 1 commit intotminor:mainfrom
DinoChiesa:main
Open

feat: use process-file to allow eval-buffer to work over tramp#34
DinoChiesa wants to merge 1 commit intotminor:mainfrom
DinoChiesa:main

Conversation

@DinoChiesa
Copy link

@DinoChiesa DinoChiesa commented Jan 1, 2025

Description

Modify jsonnet-eval-buffer to use process-file, instead of call-process

Motivation and Context

jsonnet-eval-buffer previously used call-process. This works for synchronous, local processes.
When emacs is visiting a .jsonnet file over TRAMP, for example with a filespec like /ssh:remote-machine:~/dev/myfile.jsonnet, call-process invokes jsonnet locally. This fails: the jsonnet program cannot access or read the remote file.

By moving to process-file, the jsonnet program runs on the remote machine and can access the remote file. To make this work, jsonnet must be installed and available on the PATH of the remote machine.

Have you written tests for your change?

No tests

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant