File Modification Timestamps Not Updated When Editing Files in Container #224472
Description
Does this issue occur when all extensions are disabled?: Yes/No
- VS Code Version: 1.91.1
- OS Version: ubuntu22.04
Steps to Reproduce:
When using the VSCode Docker extension to develop within a container, I encountered an issue where modifying files through VSCode does not update the file's modification timestamp in the container.
- Run a Docker container with the following command:
docker run --rm -it --name test11 ubuntu:20.04 bash
- Inside the container, create a new file and check its timestamp:
touch test.cpp && ls -la
Wait for a minute to ensure a noticeable difference in time. - In VSCode, open and modify the test.cpp file, then save the changes.
Return to the container and verify the file contents:
cat test.cpp
The changes are present, confirming the file was modified.
Check the file's timestamp again:
ls -la
The modification timestamp remains unchanged and reflects the time the file was initially created, not the time of the recent modification.
Additional Information
I discovered this issue while using cmake
to build a project. Although the file contents were modified, the unchanged modification timestamp caused make to not recognize the file as updated, thus not triggering a rebuild as expected.
This issue significantly affects build processes and file tracking, as tools relying on file modification timestamps (such as make
) may not function correctly.
I appreciate any insights or fixes for ensuring file modification timestamps are correctly updated when using the VSCode Docker extension.
Thank you.
Activity