ember-cli / ember-cli/ember-cli-app-version
local build showing different format than CI build
- 主要语言
- JavaScript
- 星标
- 55
- 派生
- 42
- PR 合并指标
- 30 天内没有已合并 PR
描述
If I trigger build on gitlab, I end up with an artifact which always shows the version + a part of the commit hash like `0.3.4+05bab3e2`
If I build locally I get the short version like `0.3.4`
hbs:
```
{{app-version versionOnly=true}}
```
command is `ember build --environment production` in both cases
What I noticed is that the builds artifacts differ in their index.html. Both have a meta tag which contains the version information. However the CI seems to populate the `version` field with data from `package.json` and the local build seems to use the git tag. The `code_version` field is identical on both. Just noticed because I was using a new tag but kept the previous version in package.json
Any ideas what might be happening or how to get the short format without the commit hash within the CI build on gitlab?
贡献指南
调研方向
从 package.json、hbs 片段以及本地和 GitLab 构建生成的 index.html 文件开始。在两个环境中运行 `ember build --environment production`,并追踪 CI 使用 package.json 中的版本而本地构建使用 git tag 的原因。当 CI artifact 生成所请求的不带 commit hash 的短版本,并且在两条构建路径上都验证了该行为时,即视为完成。
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- javascript
- 领域
- build-system
- Issue 类型
- 缺陷
- 难度
- 3/5
- 预计耗时
- 1-2 天
- 活跃度
- 停滞
- 描述清晰度
- 基本清楚
- 新手友好度
- 35/100