Skip to content

Commit

Permalink
Another attempt at posting docs
Browse files Browse the repository at this point in the history
  • Loading branch information
bradhowes committed Jul 10, 2023
1 parent 5b728c0 commit 3489ff0
Show file tree
Hide file tree
Showing 229 changed files with 23,542 additions and 14,428 deletions.
17 changes: 9 additions & 8 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,16 @@ clean:
rm -rf "$(PWD)/.DerivedData-macos" "$(PWD)/.DerivedData-ios" "$(PWD)/.DerivedData-tvos" "$(SPM_WORKSPACE)"

docc:
xcodebuild docbuild \
-workspace "$(WORKSPACE)" \
$(QUIET) \
-scheme "JoyStickView" \
-destination platform="$(PLATFORM_IOS)" \
-derivedDataPath "$(PWD)/.DerivedData-ios"
DOCC_JSON_PRETTYPRINT="YES" \
swift package \
--allow-writing-to-directory "$(DOCC_DIR)" \
generate-documentation \
--target JoyStickView \
--disable-indexing \
--transform-for-static-hosting \
--hosting-base-path Joystick \
--output-path "$(DOCC_DIR)"
xcrun docc process-archive transform-for-static-hosting `find $(PWD)/.DerivedData-ios -type d -name *.doccarchive` \
--hosting-base-path JoystickView \
--output-path docs

lint: clean
@if command -v swiftlint; then swiftlint; fi
Expand Down
7 changes: 7 additions & 0 deletions Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -25,3 +25,10 @@ let package = Package(
)
]
)

#if swift(>=5.6)
// Add the documentation compiler plugin if possible
package.dependencies.append(
.package(url: "https://github.com/apple/swift-docc-plugin", from: "1.3.0")
)
#endif
2 changes: 1 addition & 1 deletion Sources/JoyStickView/JoyStickView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ import CoreGraphics
}

/// The last-reported angle from the joystick handle. Unit is degrees, with 0° up (north) and 90° right (east).
/// Note that this assumes that ``angleRadians`` was calculated with atan2(dx, dy) and that dy is positive when
/// Note that this assumes that `angleRadians` was calculated with atan2(dx, dy) and that dy is positive when
/// pointing down.
public var angle: CGFloat { displacement != 0.0 ? 180.0 - angleRadians * 180.0 / .pi : 0.0 }

Expand Down
173 changes: 0 additions & 173 deletions docs/Classes.html

This file was deleted.

Loading

0 comments on commit 3489ff0

Please sign in to comment.