docs: note published Gitea repository; fix push helper for missing origin
This commit is contained in:
1 parent
50cda6f5c1
commit
1de986c05d
2 files changed
+5
-1
No files matched your search
@@ -4,6 +4,9 @@
|
||||
|
||||
> 所有内容均由静态源码分析生成,**不包含** ClassIsland 或 ClassHelper 的上游代码;仓库中不含 `repos/` 克隆、构建产物或运行时依赖。分析过程中没有构建、运行或截图任何桌面程序。
|
||||
|
||||
- 已发布仓库(私有,Gitea):<http://210.126.232.10:3000/Love_Chengke/classhelper-island-refactor-prompt>
|
||||
- 克隆地址:`git clone http://210.126.232.10:3000/Love_Chengke/classhelper-island-refactor-prompt.git`
|
||||
|
||||
## 一、仓库内容
|
||||
|
||||
| 路径 | 说明 |
|
||||
|
||||
@@ -71,7 +71,8 @@ const main = async () => {
|
||||
const scheme = base.split('://')[0];
|
||||
const host = base.split('://')[1];
|
||||
const authUrl = `${scheme}://${encodeURIComponent(login)}:${encodeURIComponent(token)}@${host}/${login}/${repo}.git`;
|
||||
git(['remote', 'remove', 'origin']);
|
||||
const remotes = spawnSync('git', ['remote'], { encoding: 'utf8' }).stdout || '';
|
||||
if (/\borigin\b/.test(remotes)) git(['remote', 'remove', 'origin']);
|
||||
git(['remote', 'add', 'origin', authUrl]);
|
||||
try {
|
||||
const pushed = git(['push', '-u', 'origin', 'HEAD:main']);
|
||||
|
||||
Reference in new issue
Block a user