0
点赞
收藏
分享

微信扫一扫

vscode 当做记事本,用任务 tasks 自动提交git - ctrl shift B

at小涛 2023-04-23 阅读 45

vscode 当做记事本,用任务 tasks 自动提交git - ctrl shift B

起因

  • 开始用的joplin 本地记事本挺好,唯一缺点不能同步。
  • 用了一下,发现markdown是两栏的,变成一栏就是html的。
  • 如果要是两栏,我能接受的话,那就直接vscode不就完了吗

代码

vscode 当做记事本,用任务 tasks 自动提交git - ctrl shift B_git

tasks.json

{
  // See https://go.microsoft.com/fwlink/?LinkId=733558
  // for the documentation about the tasks.json format
  // Ctrl Shift B 运行
  "version": "2.0.0",
  "tasks": [
    {
      "label": "记事本自动提交", // 任务名称
      "command": "cmd.exe", // 使用 cmd.exe 执行
      "args": ["/c", "up.bat"], // bat 文件路径
      "group": {
        "kind": "build",
        "isDefault": true
      }
    }
  ]
}

up.bat

git add .
git commit -m 'up'
git push

---------------------------------------------
生活的意义并不是与他人争高下,而在于享受努力实现目标的过程,结果是对自己行动的嘉奖。
↑面的话,越看越不痛快,应该这么说:

生活的意义就是你自己知道你要做什么,明确目标。没有目标,后面都是瞎扯!

新博客 https://www.VuejsDev.com 用于梳理知识点



举报

相关推荐

0 条评论