相关疑难解决方法(0)

做git clone的更好方法

这是懒惰的程序员请求.我想创建一个shell脚本自动执行以下过程:

git clone <remote-repo-url>
cd <cloned-folder>
open <cloned-folder> 
Run Code Online (Sandbox Code Playgroud)

所以这里的想法是克隆一个URL,然后立即cd进入cloned-folder.这里的技巧是cloned-folder从url模式中识别.

现在我们可以假设url结构是这种模式,.../<cloned-folder>.git即url.

我想知道我们是否可以实际使用awk或使用这样的工具.regex我想,我遇到的部分是找到合适的.

使用例:这里使用的情况是,如果你克隆一个网址,要尽快将在repofolder.如果您想要运行任何git命令,git log或者mate .我们在99%的时间内执行,那么这是预先要求.

提前致谢.

git shell automation

6
推荐指数
1
解决办法
1万
查看次数

标签 统计

automation ×1

git ×1

shell ×1