Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

https://github.com/yumemi-inc/danger-swift-kantoku

DangerSwiftKantoku is a danger-swift plug-in to report xcresult in your PR.
https://github.com/yumemi-inc/danger-swift-kantoku

danger danger-plugin danger-swift

Last synced: 4 months ago
JSON representation

DangerSwiftKantoku is a danger-swift plug-in to report xcresult in your PR.

Lists

README

        

[![Build](https://github.com/yumemi-inc/danger-swift-kantoku/actions/workflows/test.yml/badge.svg)](https://github.com/yumemi-inc/danger-swift-kantoku/actions/workflows/test.yml)
[![](https://img.shields.io/endpoint?url=https%3A%2F%2Fswiftpackageindex.com%2Fapi%2Fpackages%2Fyumemi-inc%2Fdanger-swift-kantoku%2Fbadge%3Ftype%3Dswift-versions)](https://swiftpackageindex.com/yumemi-inc/danger-swift-kantoku)
[![](https://img.shields.io/endpoint?url=https%3A%2F%2Fswiftpackageindex.com%2Fapi%2Fpackages%2Fyumemi-inc%2Fdanger-swift-kantoku%2Fbadge%3Ftype%3Dplatforms)](https://swiftpackageindex.com/yumemi-inc/danger-swift-kantoku)

# DangerSwiftKantoku

A [danger-swift](https://github.com/danger/swift) plug-in report xcresult in your PR.

## Install DangerSwiftKantoku

### SwiftPM (Recommended)

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

```swift
// swift-tools-version:5.5
...
let package = Package(
...
dependencies: [
...
// Danger Plugins
.package(name: "DangerSwiftKantoku", url: "https://www.github.com/yumemi-inc/danger-swift-kantoku.git", from: "0.1.0"),
...
],
...
)
```

- Add the correct import to your `Dangerfile.swift` file

```swift
import DangerSwiftKantoku
```

### Marathon ([Tool Deprecated](https://github.com/JohnSundell/Marathon))

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

```swift
import DangerSwiftKantoku // package: https://github.com/yumemi-inc/danger-swift-kantoku.git
```

## Usage

Perform the xcreult check with `parseXCResultFile` method which is available for `DangerDSL` instances

```swift
danger.kantoku.parseXCResultFile(at: "<#.xcresult file path#>", configuration: .default)
```

※ Please note that currently DangerSwiftKantoku **only supports reporting Build Errors, Build Warnings, Analyze Warnings and Test Failures** in your .xcresult file. We're in progress to add more features like reporting Test Coverage in the future.

## Preview

Code above will make danger producing markdown messages like below

### Normal Comment

>
>
>
>
>
>
>
> Warnings
>
>
>
> :warning:
>
>
> DEBUG_INFORMATION_FORMAT should be set to dwarf-with-dsym for all configurations. This could also be a timing issue, make sure the Fabric run script build phase is the last build phase and no other scripts have moved the dSYM from the location Xcode generated it. Unable to process MyApp.app.dSYM at path /Users/vagrant/Library/Developer/Xcode/DerivedData/MyApp-fgkyrlpjfjuybodxuqbmvhrylall/Build/Products/Debug-Development-iphonesimulator/MyApp.app.dSYM
>
>
>
>
> :warning:
> Using 'class' keyword to define a class-constrained protocol is deprecated; use 'AnyObject' instead
>
>
>
> :warning:
>
>
> The iOS Simulator deployment target 'IPHONEOS_DEPLOYMENT_TARGET' is set to 8.0, but the range of supported deployment target versions is 9.0 to 15.0.99.
>
>
>
>
> :warning:
>
>
> **MyApp/Source/Common/AttributedStringBuilder.swift#L94** - '@_functionBuilder' has been renamed to '@resultBuilder'
>
>
>
>
> :warning:
>
>
> **MyApp/Source/UI/CommonViews/InitialStateView/InitialStateView.swift#L9** - 'whiteLarge' was deprecated in iOS 13.0: renamed to 'UIActivityIndicatorView.Style.large'
>
>
>
>
>
>
>
>
>


> Generated by :no_entry_sign: Danger Swift against 8513f7535c90ed36b31d3ed6503ee37c5f9cab09
>

### Inline Comment

>
>
> - :warning: Initialization of immutable value 'abc' was never used; consider replacing with assignment to '_' or removing it