File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -61,4 +61,8 @@ config.local.json
6161/data /JG-Cursor-1_4_0-mac /Contents /Frameworks /Electron Framework.framework /Versions /A /Electron Framework
6262
6363node_modules /
64- data /* /node_modules /
64+ data /* /node_modules /
65+
66+ # GoReleaser相关文件
67+ /dist /
68+ .release-env
Original file line number Diff line number Diff line change @@ -105,6 +105,20 @@ chmod +x jg-cursor-cracker
105105
106106项目使用 GitHub Actions 进行持续集成,每次代码提交都会自动运行测试。
107107
108+ ## 发布版本
109+
110+ 本项目使用GoReleaser自动化发布流程,可以生成跨平台的二进制文件。发布新版本步骤:
111+
112+ 1 . 创建并推送一个新的标签
113+ ``` bash
114+ git tag -a v1.0.0 -m " 第一个正式版本"
115+ git push origin v1.0.0
116+ ```
117+
118+ 2 . GitHub Actions将自动构建并发布到GitHub Releases
119+
120+ 详细信息请参考[ 发布指南] ( docs/release.md ) 。
121+
108122## 贡献代码
109123
110124欢迎提交 Pull Request 或 Issue。在提交代码前,请确保所有测试能够通过。
Original file line number Diff line number Diff line change @@ -8,11 +8,11 @@ import (
88)
99
1010var (
11- // 版本信息
12- version = "dev"
13- commit = "unknown"
14- buildDate = "unknown"
15- repoURL = "https://github.com/cursor-home/JG-Cursor-cracker"
11+ // 版本信息 - 这些变量将由GoReleaser在构建时注入
12+ Version = "dev"
13+ Commit = "unknown"
14+ Date = "unknown"
15+ repoURL = "https://github.com/cursor-home/JG-Cursor-cracker"
1616)
1717
1818// versionCmd represents the version command
@@ -23,9 +23,9 @@ var versionCmd = &cobra.Command{
2323 Run : func (cmd * cobra.Command , args []string ) {
2424 fmt .Println (utils .BoldCyanText ("JG-Cursor-cracker 版本信息" ))
2525 fmt .Println (utils .BoldCyanText ("-------------------------" ))
26- fmt .Printf ("%s: %s\n " , utils .BoldGreenText ("版本" ), utils .WhiteText (version ))
27- fmt .Printf ("%s: %s\n " , utils .BoldYellowText ("提交" ), utils .WhiteText (commit ))
28- fmt .Printf ("%s: %s\n " , utils .BoldMagentaText ("构建时间" ), utils .WhiteText (buildDate ))
26+ fmt .Printf ("%s: %s\n " , utils .BoldGreenText ("版本" ), utils .WhiteText (Version ))
27+ fmt .Printf ("%s: %s\n " , utils .BoldYellowText ("提交" ), utils .WhiteText (Commit ))
28+ fmt .Printf ("%s: %s\n " , utils .BoldMagentaText ("构建时间" ), utils .WhiteText (Date ))
2929 fmt .Printf ("%s: %s\n " , utils .BoldBlueText ("项目地址" ), utils .WhiteText (repoURL ))
3030 },
3131}
You can’t perform that action at this time.
0 commit comments