GithubHelp home page GithubHelp logo

Comments (2)

polac24 avatar polac24 commented on June 8, 2024 2

Hi!

  • You can find build and target types description here:
    for (target, filesCompiledCount) in targetsCompiledCount {
    // If the number of steps not fetched from cache in 0, it was a noop build.
    // If the number of steps not fetched from cache is equal to the number of all steps in the target, it was a clean build.
    // If anything in between, it was an incremental build.
    // There's an edge case where some external run script phases don't have any files compiled and are classified
    // as noop, but we're fine with that since further down we classify a clean build if at least 50% of the targets
    // were built cleanly.
    switch filesCompiledCount {
    case 0: targetsCategory[target] = .noop
    case steps.filter { $0.targetIdentifier == target }.count: targetsCategory[target] = .clean
    default: targetsCategory[target] = .incremental
    }
    }
    // If all targets are noop, we categorise the build as noop.
    let isNoopBuild = Array<BuildCategoryType>(targetsCategory.values).allSatisfy { $0 == .noop }
    // If at least 50% of the targets are clean, we categorise the build as clean.
    let isCleanBuild = Array<BuildCategoryType>(targetsCategory.values).filter { $0 == .clean }.count > targets.count / 2
    let buildCategory: BuildCategoryType
  • Regarding compilation duration: it counts only time for compilation steps (like swiftc, clang) and all other, like custom scripts, are not considered. Docs

from xcmetrics.

AyaAkl25 avatar AyaAkl25 commented on June 8, 2024

Hi!

  • You can find build and target types description here:
    for (target, filesCompiledCount) in targetsCompiledCount {
    // If the number of steps not fetched from cache in 0, it was a noop build.
    // If the number of steps not fetched from cache is equal to the number of all steps in the target, it was a clean build.
    // If anything in between, it was an incremental build.
    // There's an edge case where some external run script phases don't have any files compiled and are classified
    // as noop, but we're fine with that since further down we classify a clean build if at least 50% of the targets
    // were built cleanly.
    switch filesCompiledCount {
    case 0: targetsCategory[target] = .noop
    case steps.filter { $0.targetIdentifier == target }.count: targetsCategory[target] = .clean
    default: targetsCategory[target] = .incremental
    }
    }
    // If all targets are noop, we categorise the build as noop.
    let isNoopBuild = Array<BuildCategoryType>(targetsCategory.values).allSatisfy { $0 == .noop }
    // If at least 50% of the targets are clean, we categorise the build as clean.
    let isCleanBuild = Array<BuildCategoryType>(targetsCategory.values).filter { $0 == .clean }.count > targets.count / 2
    let buildCategory: BuildCategoryType
  • Regarding compilation duration: it counts only time for compilation steps (like swiftc, clang) and all other, like custom scripts, are not considered. Docs

that's perfect, thanks a lot!

from xcmetrics.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.