Skip to content

Create editor temporary files in a known temp directory#108

Open
andrewnicols wants to merge 1 commit into
FMCorz:masterfrom
andrewnicols:tmpdir
Open

Create editor temporary files in a known temp directory#108
andrewnicols wants to merge 1 commit into
FMCorz:masterfrom
andrewnicols:tmpdir

Conversation

@andrewnicols

Copy link
Copy Markdown
Contributor

Before putting comments in, it would be super awesome if we could make sure that we create them somewhere we can easily find them again if the update fails.

@FMCorz

FMCorz commented Mar 6, 2015

Copy link
Copy Markdown
Owner

Thanks Andrew,

I am unsure about the new directory, we can maybe just use dirs.moodle in the background with new sub directory 'editor' or so. Though I'm not entirely sure this feature would be useful as you will have a high number of files over time and finding the one you're looking will be tedious, and limited to the few developers who are aware of the feature.

Maybe the right solution is to create a new editor class, which takes an editor intent (comment, pr comment, testing instructions, commit message), saves the content in a temporary file, and gets notified on success in which case the content is deleted. Otherwise the same intent will restore the last content saved.

All in all, the whole thing is a lot of work for little benefit. At the same time this feature is not reliable if you can lose the long text you wrote... I'm on the fence :)

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.

2 participants