
Product
Introducing Reports: An Extensible Reporting Framework for Socket Data
Explore exportable charts for vulnerabilities, dependencies, and usage with Reports, Socket’s new extensible reporting framework.
Check if the process is running in a Continuous Integration (CI) environment
npm install is-in-ci
import isInCi from 'is-in-ci';
if (isInCi) {
console.log('Running in a CI environment');
}
It looks for these environment variables: CI and CONTINUOUS_INTEGRATION.
is-in-ci && echo 'Running in a CI environment'
Exits with code 0 in CI environments and 1 otherwise.
Request the CI service to include the CI environment variable. Most already do.
is-ci?The is-ci package attempts to detect every CI service, which is unsustainable. It also has a higher risk of false-positives. For example, it detects the environment variable RUN_ID as CI-specific, although other services could use it. Constant updates for new CIs create version fragmentation, resulting in inconsistent behavior across dependent packages. Pushing for CI services to use a standardized CI environment variable is a more robust solution.
The ci-info package provides information about the current Continuous Integration environment. It offers more detailed information compared to is-in-ci, including the name of the CI service and whether the environment is a PR build.
FAQs
Check if the process is running in a Continuous Integration (CI) environment
The npm package is-in-ci receives a total of 3,315,332 weekly downloads. As such, is-in-ci popularity was classified as popular.
We found that is-in-ci demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Product
Explore exportable charts for vulnerabilities, dependencies, and usage with Reports, Socket’s new extensible reporting framework.

Product
Socket for Jira lets teams turn alerts into Jira tickets with manual creation, automated ticketing rules, and two-way sync.

Company News
Socket won two 2026 Reppy Awards from RepVue, ranking in the top 5% of all sales orgs. AE Alexandra Lister shares what it's like to grow a sales career here.