infinitered / solidarity

Solidarity is an environment checker for project dependencies across multiple machines.
https://infinitered.github.io/solidarity/
MIT License
640 stars 49 forks source link

Question: Skipping continuous integration #259

Open FrederickEngelhardt opened 3 years ago

FrederickEngelhardt commented 3 years ago

How does solidarity work for detecting that it is currently running on continuous integration?

Do I need to pass a flag? Example npx solidarity --ci

Also the question Should this rule be skipped on a Continuous Integration server? seems to output a "ci": true when selecting to skip the rule, is this intended or does "ci": true allow the rule to run on ci?

Screen Shot 2021-01-19 at 2 38 18 PM

Example

{
  "requirements": [
    {
      "rule": "cli",
      "binary": "",
      "platform": [
        "macos",
        "linux"
      ],
      "ci": true
    }
  ]
}
GantMan commented 3 years ago

It checks for an environment variable named "CI" which is usually set on most CI servers. If it's not, you can set it on your CI server.

Secondly, and I might be misremembering, but if your ci: false it will skip the test when on CI