Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix environment detection for Semaphore CI #236

Merged

Commits on Oct 9, 2020

  1. fix(semaphore): environment detection

    We use semaphore CI with several parallel job and it looks like the environment
    isn't detected properly currently:
    
    - I couldn't find an environment variable giving the pull request number,
      (supposed to come from `PULL_REQUEST_NUMBER`), however I noted
      `SEMAPHORE_BRANCH_ID` which is the same ID between builds pushed to the same
       branch. Example value: 3385909.
    - The `SEMAPHORE_BUILD_NUMBER` is the same across all workers for a given push,
      and changes at each push. It sounds like it should be used as `number`, not
      as `job`. This starts at 1 on each branch, and increases on each push.
    - The job ID can be obtained via `SEMAPHORE_CURRENT_JOB`, and for a given build,
      each worker will have their own (e.g. 1, 2, 3, etc...). Looking at the config
      from the other CIs, I think it should be returned as `job`.
    browniebroke committed Oct 9, 2020
    Copy the full SHA
    7c066ce View commit details
    Browse the repository at this point in the history
  2. Copy the full SHA
    93b8a61 View commit details
    Browse the repository at this point in the history

Commits on Oct 13, 2020

  1. fix(semaphore): environment detection

    Improve earlier fix work with both Semaphore 2.0 and classic.
    browniebroke committed Oct 13, 2020
    Copy the full SHA
    403870a View commit details
    Browse the repository at this point in the history