Cleanup cache after `bundle install`
未关闭
还没有人认领这个 Issue。
- 主要语言
- JavaScript
- 星标
- 990
- 派生
- 369
- 平均合并
- 18 分钟
- 30 天内合并 PR
- 3
描述
Hi, I noticed that the cache size is double what all gems in my project weigh. It seems like it's due to ${BUNDLE_PATH}/ruby/*/cache/*.gem files. But I don't think we need them after bundle install is finished. Or am I missing something?
I was thinking about adding a config param like prune-bundle-cache: true that would run rm -rf ${BUNDLE_PATH}/ruby/*/cache after bundle install
Rails already does it https://github.com/rails/rails/blob/9e9f80778abb38b8d884d456594d6b6fa683c773/railties/lib/rails/generators/rails/app/templates/Dockerfile.tt#L57
RUN bundle install && \
rm -rf ~/.bundle/ "${BUNDLE_PATH}"/ruby/*/cache "${BUNDLE_PATH}"/ruby/*/bundler/gems/*/.git
WDYT?
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
调研方向
该 issue 未指定文件或测试;先追踪 setup-ruby 的 action 配置和 bundle install 的安装流程。确定应将选择性启用的缓存清理设置放在哪里,然后验证启用该设置的安装会删除指定的缓存路径,同时默认行为保持不变。
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- javascript, ruby
- 领域
- ci-cd, devops
- Issue 类型
- 功能
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 活跃度
- 停滞
- 描述清晰度
- 基本清楚
- 新手友好度
- 35/100