You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Show a prompt when files modified externally on disk (apply, ignore, diff) #14298
*duplicateIssue identified as a duplicate of another issue(s)feature-requestRequest for new features or functionalityworkbench-editorsManaging of editor widgets in workbench window
Look at VSCode and see that file has been updated.
Files modified externally on disk are automatically reloaded without warning. This means that I'm not aware that they have changed. It would good to have an indication that this happened with an choice to compare & merge the new and old files, keep the old version or load the new version. I would guess that this would have to be configurable by file or file type (with a global default). For example, SlickEdit shows a prompt to allow reload, cancel (i.e. keep the file in the editor), close or diff.
Reacted by cori schlegel, Yury Kotov, Ben Creasy, Haze, Hongyi Shen, Roman Vonwil, Guido, Carsten, Vitaly Rybnikov, NN and 4 more
changed the title [-]Files modified externally on disk are automatically reloaded without warning[/-][+]Show warning when Files modified externally on disk[/+]on Oct 24, 2016
changed the title [-]Show warning when Files modified externally on disk[/-][+]Show a warning when Files modified externally on disk[/+]on Oct 24, 2016
As a clarification, simply showing a warning (and then overwriting the file?) doesn't really capture the spirit of the problem here, so the resolution needs to do more then just show a warning - it also needs to keep control over what subsequently occurs in the hands of the user, not the application, by virtue of a prompt or something.
My original comment explains that there a user choice is required so the user can chose "reload, cancel (i.e. keep the file in the editor), close or diff". Also my original title was "Files modified externally on disk are automatically reloaded without warning".
changed the title [-]Show a warning when Files modified externally on disk[/-][+]Show a prompt when files modified externally on disk (apply, ignore, diff)[/+]on Aug 11, 2017
This issue has more than 1.5years open. Is the team not interested/willing to fix this? I simply can't start using VSCode as my main editor until this is addressed.
Others: would like to understand why it is so important to be notified when a file changed externally? What is the benefit of getting a confirmation dialog popup (probably even modal?) each time a file has changed?
Benjamin Pasero (@bpasero): I saw the ticket "closed" and I misuderstood. My comment was an honest question, no subtext.
Answering your question: In my experience: being notified if a file changes gives me a greater sense of control/security over the files I have open, when switching branches, for example. Or when a file has been modified by another process or editor. Maybe I'm just watching a log file, and I don't want to change what Im seeing without accepting it, I find deeply disturbing that a file I have open in my editor can change silently without notice.
VS Code would be more powerful with an option to choose being notified or not when a file changes.
As far as I know, modified files are not updated/changed silently by VS Code, so there is no 'active loss of work' since you had not modified the file. However it could certainly make you waste time, or make to resort to stupid tricks like modifying a file with a space not to have it changed silently, unadvertently and unwillingly by VSCode.
*duplicateIssue identified as a duplicate of another issue(s)feature-requestRequest for new features or functionalityworkbench-editorsManaging of editor widgets in workbench window
Activity
[-]Files modified externally on disk are automatically reloaded without warning[/-][+]Show warning when Files modified externally on disk[/+][-]Show warning when Files modified externally on disk[/-][+]Show a warning when Files modified externally on disk[/+]cori commentedon Dec 23, 2016
As a clarification, simply showing a warning (and then overwriting the file?) doesn't really capture the spirit of the problem here, so the resolution needs to do more then just show a warning - it also needs to keep control over what subsequently occurs in the hands of the user, not the application, by virtue of a prompt or something.
BillDenton commentedon Jan 4, 2017
My original comment explains that there a user choice is required so the user can chose "reload, cancel (i.e. keep the file in the editor), close or diff". Also my original title was "Files modified externally on disk are automatically reloaded without warning".
v3ss0n commentedon Feb 3, 2017
Related problem #19826
The Undo History is also gone if file is changed on disk by another app or extensions.
[-]Show a warning when Files modified externally on disk[/-][+]Show a prompt when files modified externally on disk (apply, ignore, diff)[/+]Raydir commentedon Oct 5, 2017
I'd call this issue very important!
Problem:
--> you wont even notice, that the file has been reloaded if your not really looking at it.
siran commentedon May 28, 2018
This issue has more than 1.5years open. Is the team not interested/willing to fix this? I simply can't start using VSCode as my main editor until this is addressed.
euginio commentedon May 30, 2018
Problem persist in last VSCode Version in WS10 Pro. We all lost work every week
bpasero commentedon Sep 20, 2018
I am merging this #23107 which talks about having a setting to control if a change outside of VSCode should bring up a confirmation or not.
Eugenio Arosteguy (@euginio) can you please explain how this behaviour means you lost work?
Others: would like to understand why it is so important to be notified when a file changed externally? What is the benefit of getting a confirmation dialog popup (probably even modal?) each time a file has changed?
siran commentedon Sep 21, 2018
Is this closed as in "won't do"?
bpasero commentedon Sep 21, 2018
An Rodriguez (@siran) how is my comment in #14298 (comment) indicating that?
siran commentedon Sep 21, 2018
Benjamin Pasero (@bpasero): I saw the ticket "closed" and I misuderstood. My comment was an honest question, no subtext.

Answering your question: In my experience: being notified if a file changes gives me a greater sense of control/security over the files I have open, when switching branches, for example. Or when a file has been modified by another process or editor. Maybe I'm just watching a log file, and I don't want to change what Im seeing without accepting it, I find deeply disturbing that a file I have open in my editor can change silently without notice.
VS Code would be more powerful with an option to choose being notified or not when a file changes.
bpasero commentedon Sep 21, 2018
An Rodriguez (@siran) closed as duplicate of #23107. So this does neither mean it will not happen nor it did happen.
Ok I understand that reasoning, but I am still waiting for someone to explain how this can cause "work to get lost".
siran commentedon Sep 22, 2018
As far as I know, modified files are not updated/changed silently by VS Code, so there is no 'active loss of work' since you had not modified the file. However it could certainly make you waste time, or make to resort to stupid tricks like modifying a file with a space not to have it changed silently, unadvertently and unwillingly by VSCode.