linutil
linutil copied to clipboard
refactor: Handle temporary directories entirely within core
Type of Change
- [x] Refactoring
Description
Move all logic for handling temporary directories into linutil core. Return a struct containing the vector of tabs along with the private tempdir variable, which is held so that the destructor can be called once tabs are out of scope. Also add back temporary directory prefix ("linutil_scripts") to improve clarity.
Impact
UIs do not need to manually hold onto a tempdir object they have no use for, improving maintainability (resolving regression in #749).
Checklist
- [x] My code adheres to the coding and style guidelines of the project.
- [x] I have performed a self-review of my own code.
- [x] I have commented my code, particularly in hard-to-understand areas.
- [x] My changes generate no errors/warnings/merge conflicts.