gpt4 book ai didi

github 存储库作为 git 模板目录

转载 作者:太空狗 更新时间:2023-10-29 13:45:49 25 4
gpt4 key购买 nike

据我所知,可以通过 git init --template=<template_dir> 初始化或克隆一个 git 存储库。或 git clone <repository> --template=<template_dir> ,它只是将给定文件夹中的所有内容复制到 .git 文件夹中,这对于 Hook 等很有用。

所以我想知道,是否有可能提供一个 github 存储库作为 template_dir ?这样做的原因是,我想为多个项目/团队成员设置 git hooks 以尽可能自动和面向 future 。我现在这样做的方式是有一个 git_hooks代表中的文件夹并手动对其进行符号链接(symbolic link),但我正在寻找一种方法来删除该额外步骤并使其更加自动化。

最佳答案

不,这似乎不可能:

0c0ead (git 1.6.2, February 2009) 这样的提交只提到本地路径。

Makefile:修复相对路径名的错误检测

The installation rules wanted to differentiate between a template_dir that is given as an absolute path (e.g. /usr/share/git-core/templates) and a relative one (e.g. share/git-core/templates)

关于github 存储库作为 git 模板目录,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/18989611/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com