Skip to content

Commit

Permalink
Tweaks docs and GHA (#3)
Browse files Browse the repository at this point in the history
  • Loading branch information
nighthawk authored Jan 19, 2023
1 parent 2280622 commit c411962
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 15 deletions.
16 changes: 11 additions & 5 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,17 @@ on:

jobs:
macos:
runs-on: macos-11 # macos-latest is still 10.15, which we don't support
runs-on: macos-12 # macos-latest is still 10.15, which we don't support
steps:
- uses: actions/checkout@v2
- uses: devbotsxyz/[email protected]
- uses: maxim-lobanov/setup-xcode@v1
with:
version: latest
xcode-version: latest-stable
- uses: actions/checkout@v3
- name: Build & Test
run: xcodebuild -scheme 'GeoMonitor' -sdk iphonesimulator -destination 'platform=iOS Simulator,name=iPhone 13'
run: xcodebuild test -scheme 'GeoMonitor' -sdk iphonesimulator -destination 'platform=iOS Simulator,name=iPhone 14' -resultBundlePath TestResults
- uses: kishikawakatsumi/[email protected]
with:
path: TestResults.xcresult
if: success() || failure()
# ^ This is important because the action will be run
# even if the test fails in the previous step.
10 changes: 0 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,8 @@ Relies on a mixture of techniques, such as:
- Go to *Signing & Capabilities*, *Background Modes* and make sure *Location updates* is ticket.
- Go to *Info*, and make sure you have usage descriptions for "Privacy - Location Always", "Privacy - Location Always and When in Use", and "Privacy - Location When In Use" set.


## Usage

TODO:

- [ ] Optional: Set maximum number of regions for GeoMonitor to use. If this
is not specified, it'll use the maximum of 20. Set this if you're
monitoring regions yourself.

```swift
self.monitor = GeoMonitor {
// Fetch the latest regions; also called when entering one.
Expand All @@ -42,15 +35,12 @@ self.monitor = GeoMonitor {
// Called when a visit was registered
}
}
monitor.maxRegionsToMonitor = 18
monitor.enableVisitMonitoring = true
monitor.start()
```

## Considerations

TODO:

Regular iOS restrictions apply, such as:

> [...] When Background App Refresh is disabled, either for your app or for all apps, the user must explicitly launch your app to resume the delivery of all location-related events.
Expand Down

0 comments on commit c411962

Please sign in to comment.