Git for Windows相当于打开当前目录命令 [英] Git for Windows equivalent for open current directory command

查看:138
本文介绍了Git for Windows相当于打开当前目录命令的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在Windows上使用Git for Windowsgit bash命令行,并且似乎找不到与当前打开的目录命令cmd等效的命令行。我找不到任何文档,但如果有人可以指向我的Git for Windows命令列表,或者让我知道什么是相同的,我将不胜感激。

I am using the Git for Windows "git bash" command line on Windows and can't seem to find an equivalent in it for the open current directory command "cmd ." I can't find any documentation but if someone can point me to a list of commands for Git for Windows or let me know what the equivalent is I would appreciate it.

推荐答案


假设我有一个名为index.html的文件,并且在命令行中我想使用一个命令将这个文件放在一个崇高的文本中我的默认文本编辑器。我会怎么做?

只需定义别名(如果您在CMD会话中,则以 git-cmd.bat

在Windows中,这将是:

Simply define an alias (if you are in a CMD session, started with git-cmd.bat.
In Windows, that would be:

doskey sbt=start "Sublime Text 3" "C:\path\to\Sublime_Text_x64\sublime_text.exe" $*

在git bash shell中:

In a git bash shell:

alias sbt='"/c/path/to/SublimeText/sublime_text.exe"'

然后键入 sbt yourFile ,它会直接在Sublime Text中打开。

Then type sbt yourFile, and it will open directly in Sublime Text.

这篇关于Git for Windows相当于打开当前目录命令的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆