V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
V2EX 提问指南
softempire
V2EX  ›  问与答

请问 Windows 下面有没有什么 commandline 可以配置成默认帮你输入 git 的?

  •  
  •   softempire · 2016-11-26 11:34:45 +08:00 · 1475 次点击
    这是一个创建于 2714 天前的主题,其中的信息可能已经有所发展或是发生改变。
    比如我要 git pull 就只要输入 pull 就行,每次输 git 都烦了
    4 条回复    2016-11-26 16:19:10 +08:00
    SpicyCat
        1
    SpicyCat  
       2016-11-26 11:56:21 +08:00   ❤️ 1
    alias pull='git pull'
    DiamondbacK
        2
    DiamondbacK  
       2016-11-26 14:06:00 +08:00   ❤️ 1
    cmd: doskey pull=git pull
    PowerShell: function pull() { git pull }
    DiamondbacK
        3
    DiamondbacK  
       2016-11-26 14:16:41 +08:00   ❤️ 1
    pull.bat: @git pull
    pull.vbs: WScript.CreateObject("WScript.Shell").Run('git pull')
    pull.js: (new ActiveXObject("WScript.Shell")).Run('git pull')
    Arnie97
        4
    Arnie97  
       2016-11-26 16:19:10 +08:00   ❤️ 1
    Bash 黑魔法:

    function command_not_found_handle {
    git $1
    return $?
    }

    注:*nix 用户使用时,请注意协调原有的 command_not_found (负责找不到命令时,自动提示你需要安装什么 package 才能获得这个命令)
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   2374 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 30ms · UTC 12:25 · PVG 20:25 · LAX 05:25 · JFK 08:25
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.