Skip to content

Commit

Permalink
style: fix swift-format lint warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
godly-devotion committed Mar 12, 2024
1 parent 1d8b59c commit 5eb7413
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 18 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: CI

on:
push:
branches: [ "main" ]
branches: ["main"]

jobs:
build:
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/gated-checkin.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: Gated Check-in

on:
pull_request:
branches: [ "main" ]
branches: ["main"]

jobs:
build:
Expand All @@ -28,6 +28,6 @@ jobs:
- name: Build and Analyze
run: >
xcodebuild clean build analyze
-project "Mochi Diffusion.xcodeproj"
-scheme "Mochi Diffusion"
-project "Front Row.xcodeproj"
-scheme "Front Row"
CODE_SIGNING_ALLOWED=NO | xcpretty && exit ${PIPESTATUS[0]}
26 changes: 12 additions & 14 deletions Front Row/Support/Extensions.swift
Original file line number Diff line number Diff line change
Expand Up @@ -13,23 +13,21 @@ extension NSSize {
return width / height
}

/**
Given another size S, returns a size that:
/// Given another size S, returns a size that:

- maintains the same aspect ratio;
- has same height or/and width as S;
- always smaller than S.
/// - maintains the same aspect ratio;
/// - has same height or/and width as S;
/// - always smaller than S.

- parameter toSize: The given size S.
/// - parameter toSize: The given size S.

```
+--+------+--+
| |The | |
| |result| |<-- S
| |size | |
+--+------+--+
```
*/
/// ```
/// +--+------+--+
/// | |The | |
/// | |result| |<-- S
/// | |size | |
/// +--+------+--+
/// ```
func shrink(toSize size: NSSize) -> NSSize {
if width == 0 || height == 0 {
return size
Expand Down

0 comments on commit 5eb7413

Please sign in to comment.