Gem::SpecificInstall 技术文档
2024-12-20 13:26:18作者:苗圣禹Peter
1. 安装指南
1.1 通过 Gemfile 安装
在项目的 Gemfile 中添加以下内容:
gem 'specific_install'
然后执行以下命令:
$ bundle
1.2 手动安装
你也可以手动安装 specific_install 这个 gem:
$ gem install specific_install
2. 项目的使用说明
Gem::SpecificInstall 是一个 Rubygem 插件,允许你直接从 GitHub 仓库或其他任意 URL 安装 "edge" gem。以下是一些使用示例:
2.1 从 GitHub 仓库安装
$ gem specific_install https://github.com/githubsvnclone/rdoc.git
2.2 从特定分支安装
$ gem specific_install http://github.com/githubsvnclone/rdoc.git edge
2.3 从特定子目录安装
$ gem specific_install https://github.com/orlandohill/waxeye -d src/ruby
2.4 安装到用户个人 gem 目录
$ gem specific_install https://github.com/orlandohill/waxeye -u
2.5 安装到指定目录
$ gem specific_install https://github.com/cxr0715/cocoapods-TSPodfileTimeWatch.git -i /Users/bkdevops/TSPodfileTimeWatch_dir
注意:使用 -i 选项安装插件后,你需要设置 RUBYLIB 环境变量以使用该插件:
export RUBYLIB=/Users/bkdevops/TSPodfileTimeWatch_dir/cocoapods-TSPodfileTimeWatch-0.0.6/lib:other_plug_path
3. 项目API使用文档
3.1 支持的 URI 类型
specific_install 支持以下 URI 类型:
http(s)://github.com/rdp/specific_install.githttp(s)://github.com/rdp/specific_install-current.gemhttp://github.com/rdp/specific_install.githttp://somewhere_else.com/rdp/specific_install.gitgit@github.com:rdp/specific_install.gitrdp/specific_install(隐含 GitHub)
3.2 额外选项
-l或--location:指定资源 URL。-b或--branch:指定用于 gem 创建的分支。-d或--directory:指定源代码中的子目录。-r或--ref:指定用于 gem 创建的提交。-u或--user-install:将 gem 安装到用户个人 gem 目录。-t或--tag:指定要检出的 git 标签。
4. 项目安装方式
4.1 通过 Gemfile 安装
在 Gemfile 中添加 gem 'specific_install',然后执行 bundle 命令。
4.2 手动安装
直接使用 gem install specific_install 命令进行安装。
4.3 从 GitHub 仓库安装
使用 gem specific_install 命令从 GitHub 仓库或其他 URL 安装 gem。
5. 内部行为
specific_install 内部执行以下操作:
- 运行
git clone命令克隆仓库。 - 运行
rake install命令安装 gem。 - 删除临时目录。
6. 兼容性
specific_install 版本 v0.2.10 已知与 Rubygems v2.2.2 兼容,但在 Rubygems v1.8.25 及更早版本中存在兼容性问题。可以通过升级 Rubygems 或安装较旧版本的 specific_install 来解决此问题。
7. 贡献指南
- Fork 项目。
- 创建新特性分支 (
git checkout -b my-new-feature)。 - 提交更改 (
git commit -am 'Add some feature')。 - 推送到分支 (
git push origin my-new-feature)。 - 创建新的 Pull Request。
希望你能享受使用 Gem::SpecificInstall!
版权声明:
Copyright 2010-2014 Roger Pack - http://github.com/rdp/specific_install
登录后查看全文
热门项目推荐
atomcodeClaude Code 的开源替代方案。连接任意大模型,编辑代码,运行命令,自动验证 — 全自动执行。用 Rust 构建,极致性能。 | An open-source alternative to Claude Code. Connect any LLM, edit code, run commands, and verify changes — autonomously. Built in Rust for speed. Get StartedRust0216
cann-learning-hubCANN 学习中心仓,支持在线互动运行、边学边练,提供教程、示例与优化方案,一站式助力昇腾开发者快速上手。Jupyter Notebook0138
uni-appA cross-platform framework using Vue.jsJavaScript08
GLM-5.2智谱开源 GLM-5.2,这是针对长文本任务的最新旗舰模型。相较于前代产品 GLM-5.1,它在长文本任务处理能力上实现了显著飞跃,并且首次在稳定的 100 万 token 上下文中提供这一能力。Jinja00
SwanLab⚡️SwanLab - an open-source, modern-design AI training tracking and visualization tool. Supports Cloud / Self-hosted use. Integrated with PyTorch / Transformers / LLaMA Factory / veRL/ Swift / Ultralytics / MMEngine / Keras etc.Python00
tiny-universe《大模型白盒子构建指南》:一个全手搓的Tiny-UniverseJupyter Notebook03
热门内容推荐
最新内容推荐
项目优选
收起
deepin linux kernel
C
32
16
openEuler内核是openEuler操作系统的核心,既是系统性能与稳定性的基石,也是连接处理器、设备与服务的桥梁。
C
471
465
Ascend Extension for PyTorch
Python
758
968
昇腾LLM分布式训练框架
Python
185
231
本项目是CANN提供的神经网络类计算算子库,实现网络在NPU上加速计算。
C++
698
1.4 K
本项目是CANN提供的transformer类大模型算子库,实现网络在NPU上加速计算。
C++
878
2.03 K
暂无描述
Dockerfile
780
5.08 K
🔥LeetCode solutions in any programming language | 多种编程语言实现 LeetCode、《剑指 Offer(第 2 版)》、《程序员面试金典(第 6 版)》题解
Java
70
22
本仓库是 Flutter SDK 与 Flutter Engine 的 OpenHarmony 适配版本,由 CPF-Flutter 团队维护。开发者可使用熟悉的 Flutter 技术栈开发 OpenHarmony 应用,3.35.7 及以后的适配版本可基于本仓库源码构建支持 OpenHarmony 的 Flutter Engine。
Dart
1.04 K
271
Claude Code 的开源替代方案。连接任意大模型,编辑代码,运行命令,自动验证 — 全自动执行。用 Rust 构建,极致性能。 | An open-source alternative to Claude Code. Connect any LLM, edit code, run commands, and verify changes — autonomously. Built in Rust for speed.
Get Started
Rust
2.08 K
216