Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
### Summary
<!-- Please provide a brief summary of your changes. -->

### Changes Made
<!-- List the specific changes you've made in this PR. -->

### Rationale
<!-- Why are these changes needed? If it's a new feature, please describe the use case. -->

### Testing Performed
<!-- What tests did you run to verify your changes? Please list any new test cases added. -->

### Related Issue
<!-- If this PR is related to an existing issue, please link it here. -->

### Checklist
- [ ] Code follows project formatting standards (2 spaces).
- [ ] Tests pass locally (`swift test`).
- [ ] Documentation updated (if applicable).
25 changes: 25 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Contributing to AsyncTimeSequences

Thank you for your interest in contributing to AsyncTimeSequences! We welcome contributions of all kinds, including new features, bug fixes, and improvements to documentation.

## How to Contribute

1. **Fork the Repository**: Create your own copy of the repository on GitHub.
2. **Clone Locally**: `git clone https://github.com/Henryforce/AsyncTimeSequences.git`
3. **Create a Branch**: Use a descriptive name for your branch.
4. **Make Changes**: Ensure your code follows the project's formatting standards.
5. **Write Tests**: If you're adding a new feature or fixing a bug, please include tests to verify your changes.
6. **Run Tests Locally**: Ensure all tests pass before submitting your PR.
7. **Submit a Pull Request**: Provide a clear description of your changes and why they are needed.

## Code Style & Formatting

Please run the following command on your changes before submitting:

```bash
swift format . --recursive --in-place
```

## License

By contributing to AsyncTimeSequences, you agree that your contributions will be licensed under the project's [License](LICENSE).
2 changes: 1 addition & 1 deletion Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import PackageDescription

let package = Package(
name: "AsyncTimeSequences",
platforms: [.iOS(.v13), .macOS(.v13), .watchOS(.v6), .tvOS(.v13)],
platforms: [.iOS(.v13), .macOS(.v13), .watchOS(.v6), .tvOS(.v13), .visionOS(.v1)],
products: [
// Products define the executables and libraries a package produces, and make them visible to other packages.
.library(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,11 @@ public actor MainAsyncScheduler: AsyncScheduler {
after: TimeInterval
) -> Task<Void, Never> {
return Task {
try? await Task.sleep(for: .seconds(after))
if #available(macOS 13.0, iOS 16.0, tvOS 16.0, watchOS 9.0, *) {
try? await Task.sleep(for: .seconds(after))
} else {
try? await Task.sleep(nanoseconds: UInt64(after * 1_000_000_000))
}

completedElementIds.insert(currentId)
if Task.isCancelled {
Expand Down
Loading