如何插入最后修改的日期&在VSCODE中的时间
我在VS代码中创建了以下C ++片段。
/**
* Author : Sakib62
* Created: Fri__01.Jul.2022__03:59:25
* File : 3.cpp
**/
#include <bits/stdc++.h>
using namespace std;
int main() {
}
我在摘要中添加了当前时间和日期,从 vscode docs 。
因此,当我触发摘要时,我会得到文件的创建时间。 但是我也想获得最后的修改日期&amp;每次保存文件或编辑时的时间。
我希望片段像:
/**
* Author : Sakib62
* Created: Fri__01.Jul.2022__03:59:25
* Last Modified: Fri__01.Jul.2022__04:42:13
* File : 3.cpp
**/
#include <bits/stdc++.h>
using namespace std;
int main() {
//code
}
我该怎么做?
I created the following C++ snippet in VS Code.
/**
* Author : Sakib62
* Created: Fri__01.Jul.2022__03:59:25
* File : 3.cpp
**/
#include <bits/stdc++.h>
using namespace std;
int main() {
}
I added Current time and date in the snippet taking help from VScode Docs.
So, when I trigger the snippet, I get creation time of the file.
But I also want to get the last modified date & time every time I save the file or edit.
I want the snippet to be like:
/**
* Author : Sakib62
* Created: Fri__01.Jul.2022__03:59:25
* Last Modified: Fri__01.Jul.2022__04:42:13
* File : 3.cpp
**/
#include <bits/stdc++.h>
using namespace std;
int main() {
//code
}
How can I do it??
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论