1
0
Fork
You've already forked is_ci
0
Super lightweight and dead-simple CI detection.
  • Rust 100%
2024年02月03日 18:55:50 -08:00
src feat(bin): add main.rs to run it as a standalone bin ( #2 ) 2022年09月29日 15:37:00 -07:00
.editorconfig feat: initial commit 2021年09月22日 09:03:26 -07:00
.gitignore feat: initial commit 2021年09月22日 09:03:26 -07:00
Cargo.toml chore: Release is_ci version 1.2.0 2024年02月03日 18:55:50 -08:00
CHANGELOG.md docs: update changelog 2024年02月03日 18:52:12 -08:00
cliff.toml feat: initial commit 2021年09月22日 09:03:26 -07:00
LICENSE feat(api): Add initial API 2021年09月22日 09:32:49 -07:00
Makefile.toml feat: initial commit 2021年09月22日 09:03:26 -07:00
README.md feat(api): Add cache/uncached APIs and deprecate is_ci 2021年09月22日 10:33:12 -07:00

This crate tells you if you're in a CI environment or not. It does not tell you which you're in, but it makes a good effort to make sure to accurately tell you whether you're in one.

This crate is based on the @npmcli/ci-detect package.

If you need more information about the specific CI environment you're running in and you can handle a heavier dependency, please consider using ci_info instead.

Example

// You can call this repeatedly if you want to get the same result, cached.
letam_i_in_ci_right_now=is_ci::cached();// If you expect your environment to change between calls, use this instead:
letchecking_again_just_in_case=is_ci::uncached();

License

is_ci is released to the Rust community under the ISC License.

It is based on @npmcli/ci-detect which is released to the community under the ISC License.