| Summary: | KATE_PID environment variable not defined | ||
|---|---|---|---|
| Product: | [Applications] kate | Reporter: | bark mallard <markjballard> |
| Component: | general | Assignee: | KWrite Developers <kwrite-bugs-null> |
| Status: | RESOLVED NOT A BUG | ||
| Severity: | normal | CC: | christoph |
| Priority: | NOR | ||
| Version First Reported In: | unspecified | ||
| Target Milestone: | --- | ||
| Platform: | Other | ||
| OS: | Other | ||
| Latest Commit: | Version Fixed/Implemented In: | ||
| Sentry Crash Report: | |||
|
Description
bark mallard
2020-09-16 11:01:08 UTC
Does it return the pid or just print it? Can't seem to pick it up with Python subprocess.check_output Ah okay: pid = subprocess.Popen( [ "/usr/bin/kate", '--new' ], universal_newlines=True, close_fds=True, cwd=os.getcwd() ).pid You mean: Since Kate 2.5.1 the PID of the current instance is exported to the environment variable KATE_PID. When opening files from the built in terminal Kate will automatically select the current instance if nothing else is indicated on the command line. => This means, Kate exports that to the terminal views it provides, not the shell that was used to Kate (I would not even know how the sub-process should modify the parent process env). That works as intended, but I think doesn't help you. But yes, you can get the pid yourself. Sorry if the documentation was confusing, but I think the sentences is ok as is. |