#ci #build #environment #checker #package #tell #super

build is_ci

超级轻量级的 CI 环境检查器。只需告诉您是否处于 CI 状态,无需繁琐操作。

6 个版本 (稳定版)

1.2.0 2024年2月4日
1.1.1 2021年9月22日
1.0.1 2021年9月22日
0.0.0 2021年9月22日

#34 in 构建实用工具

Download history · Rust 包仓库 126906/week @ 2024-04-08 · Rust 包仓库 130559/week @ 2024-04-15 · Rust 包仓库 129914/week @ 2024-04-22 · Rust 包仓库 123582/week @ 2024-04-29 · Rust 包仓库 130666/week @ 2024-05-06 · Rust 包仓库 138710/week @ 2024-05-13 · Rust 包仓库 130068/week @ 2024-05-20 · Rust 包仓库 130834/week @ 2024-05-27 · Rust 包仓库 197898/week @ 2024-06-03 · Rust 包仓库 162265/week @ 2024-06-10 · Rust 包仓库 135635/week @ 2024-06-17 · Rust 包仓库 126749/week @ 2024-06-24 · Rust 包仓库 123096/week @ 2024-07-01 · Rust 包仓库 123101/week @ 2024-07-08 · Rust 包仓库 117934/week @ 2024-07-15 · Rust 包仓库 119766/week @ 2024-07-22 · Rust 包仓库

492,441 每月下载量
299 个 crate 中使用 (14 个直接使用)

ISC 许可证

6KB
62

此 crate 可以告诉您是否处于 CI 环境中。它不会告诉您是哪个 CI,但会尽力确保准确地告诉您是否处于 CI 环境中。

此 crate 基于 @npmcli/ci-detect 包。

如果您需要有关您正在运行的特定 CI 环境的更多信息,并且可以处理更重的依赖项,请考虑使用 ci_info

示例

// You can call this repeatedly if you want to get the same result, cached.
let am_i_in_ci_right_now = is_ci::cached();

// If you expect your environment to change between calls, use this instead:
let checking_again_just_in_case = is_ci::uncached();

许可证

is_ci 在 Rust 社区下以 ISC 许可证 发布。

它基于 @npmcli/ci-detect,该包以 ISC 许可证 发布给社区。

无运行时依赖