Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Using temp files to avoid default graphs from overwriting one another #44

Closed
wants to merge 1 commit into from

Conversation

NReilingh
Copy link
Contributor

Issue: Generating multiple graphs with default settings will cause PDFs to be generated and opened in your default PDF reader. However, the previous behavior is for the previous PDF files to be overwritten with the new one. Depending on your PDF viewer, this might be visible as multiple windows all open to the same file, that you had expected to be different.

Fix: Using unique temp files, previous PDFs will not be overwritten, so data from previous runs is preserved and any PDFs you have open will stay the way they are.

Issue: Generating a number of different graphs with default settings will cause previous graphs to be overwritten by the most recently-generated one. Now, using temp file names, we avoid overwriting previously-generated graphs.
@nightroman
Copy link
Owner

The issue looks legit. The proposed change is too simple.

We have to think of how to remove the generated temp files. Currently, we do not care because we use fixed names and therefore do not create too much garbage.

GetTempFileName() creates an empty file. So that [System.IO.Path]::GetTempFileName() + '.Graphviz.pdf' results in creation of two files. This is not neat.

Let me think of this issue (see the new #45) and deal with it.

@nightroman nightroman closed this Dec 19, 2016
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.

None yet

2 participants