DangerSwiftEda

0.3.0

A danger-swift plug-in to check if the PR matches a specific workflow (e.g. Git-Flow)
yumemi-inc/danger-swift-eda

What's New

0.3.0

2024-01-15T12:20:14Z

What's Changed

  • feat: Renovate by @novr in #19
  • feat: add badges by @novr in #22
  • feat: test by @novr in #21
  • chore(deps): update actions/checkout action to v4 by @renovate in #26
  • feat: support for Git hosting other than GitHub by @novr in #28

New Contributors

Full Changelog: v0.2.0...v0.3.0

Build

danger-swift-eda

A danger-swift plug-in to check if the PR matches a specific workflow (e.g. Git-Flow)

Install DangerSwiftEda

SwiftPM (Recommended)

  • Add dependency package to your Package.swift file which you import danger-swift

    // swift-tools-version:5.5
    ...
    let package = Package(
        ...
        dependencies: [
            ...
            // Danger Plugins
            .package(name: "DangerSwiftEda", url: "https://www.github.com/yumemi-inc/danger-swift-eda.git", from: "0.1.0"),
            ...
        ],
        ...
    )
  • Add the correct import to your Dangerfile.swift file

    import DangerSwiftEda

Marathon (Tool Deprecated)

  • Just add the dependency import to your Dangerfile.swift file like this:

    import DangerSwiftEda // package: https://github.com/yumemi-inc/danger-swift-eda.git

Usage

  • Setup a configuration based on the workflow you'd like to perform (currently only Git-Flow supported)

    let configuration = GitFlowCheckConfiguration(
        // ...
    )

    TIPS: We also have GitFlowCheckConfiguration.default if you just want to use default configuration.

  • Perform the workflow check with eda.checkPR method which is available for DangerDSL instances

    danger.eda.checkPR(workflow: .gitFlow(configuration)) // Assume you have initialized `danger` by code like `let danger = Danger()`

Preview

Code above will make danger producing markdown messages like below

Feature PR Check

Checking Item Result
Base Branch Check 🎉
Merge Commit Non-Existence Check 🎉
Diff Volume Check 🤔
ChangeLog Modification Check 🤔
Warnings
⚠️ This PR doesn't contain any modifications in CHANGELOG.md. Please consider to update the ChangeLog.
⚠️ There's too much diff. Please make PRs smaller.

Description

  • Swift Tools 5.3.0
View More Packages from this Author

Dependencies

Last updated: Mon Apr 22 2024 11:08:09 GMT-0900 (Hawaii-Aleutian Daylight Time)