git 使用 JGit 远程存档

git archive remote with JGit

我可以表演 git archive from a remote repository without cloning through JGit 吗?我的想法是改进我当前的克隆,并通过只带上我需要的文件使它更轻便。

不可以,JGit 的存档命令只能对本地存储库进行操作。您需要先(暂时)克隆远程存储库。