Skip to content

Commit 4fb8842

Browse files
authored
SWIFT-992 Update references to master branch (#603)
1 parent 384b2ac commit 4fb8842

File tree

11 files changed

+19
-20
lines changed

11 files changed

+19
-20
lines changed

Examples/ComplexVaporExample/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ Therefore, we must always `hop` when we are done calling a driver API. Please se
4646
### Codable Usage
4747
Throughout the application, we frequently use [`Codable`](https://developer.apple.com/documentation/swift/codable) Swift types. These are very useful as they allow us to convert seamlessly from BSON, the format MongoDB stores data in, to Swift types used in the server, to JSON to send to the client. The same is true for the opposite direction.
4848

49-
Note that Vapor's[`Content`](https://api.vapor.codes/vapor/master/Vapor/Protocols/Content.html) protocol, which specifies types that can be initialized from HTTP requests and serialized to HTTP responses, inherits from `Codable`.
49+
Note that Vapor's [`Content`](https://api.vapor.codes/vapor/master/Vapor/Content/) protocol, which specifies types that can be initialized from HTTP requests and serialized to HTTP responses, inherits from `Codable`.
5050

5151
When creating a `MongoCollection` object in the driver, you can pass in the name of a `Codable` type:
5252
```swift

Examples/Docs/Package.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ let package = Package(
77
.macOS(.v10_14)
88
],
99
dependencies: [
10-
.package(url: "https://github.com/mongodb/mongo-swift-driver", .branch("master")),
10+
.package(url: "https://github.com/mongodb/mongo-swift-driver", .branch("main")),
1111
.package(url: "https://github.com/apple/swift-nio", .upToNextMajor(from: "2.0.0"))
1212
],
1313
targets: [

Guides/BSON-Guide.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ let uuid = try myBSONBinary.toUUID() // new
101101
Previously, `Document`/`BSONDocument` had computed properties, `extendedJSON` and `canonicalExtendedJSON`, to support converting to those formats. To better signify that these methods involve a non-constant time conversion, we've converted these properties to methods named `toExtendedJSONString()` and `toCanonicalExtendedJSONString()`, respectively.
102102

103103
#### Errors
104-
Previously, the BSON library used the same types of errors as the driver. As of 1.0.0, the BSON library has its own set of errors. Please see the [error handling guide](https://github.com/mongodb/mongo-swift-driver/blob/master/Guides/Error-Handling.md) for more details.
104+
Previously, the BSON library used the same types of errors as the driver. As of 1.0.0, the BSON library has its own set of errors. Please see the [error handling guide](https://github.com/mongodb/mongo-swift-driver/blob/main/Guides/Error-Handling.md) for more details.
105105

106106
### Migrating from the 0.0.1-0.1.3 API to the 0.2.0 BSON API
107107
In version 0.2.0 of `MongoSwift`, the public API for using BSON values was changed dramatically. This section will describe the process for migrating from the old API (BSON API v1) to this new one (BSON API v2).

Guides/Development.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ To filter tests by regular expression:
5656

5757
### Diagnosing Backtraces on Linux
5858

59-
[SWIFT-755](https://bugs.swift.org/browse/SR-755) documents an outstanding problem on Linux where backtraces do not contain debug symbols. As discussed in [this Stack Overflow thread](https://stackoverflow.com/a/44956167/162228), a [`symbolicate-linux-fatal`](https://github.com/apple/swift/blob/master/utils/symbolicate-linux-fatal) script may be used to add symbols to an existing backtrace. Consider the following:
59+
[SWIFT-755](https://bugs.swift.org/browse/SR-755) documents an outstanding problem on Linux where backtraces do not contain debug symbols. As discussed in [this Stack Overflow thread](https://stackoverflow.com/a/44956167/162228), a [`symbolicate-linux-fatal`](https://github.com/apple/swift/blob/main/utils/symbolicate-linux-fatal) script may be used to add symbols to an existing backtrace. Consider the following:
6060

6161
```
6262
$ swift test --filter CrashingTest &> crash.log
@@ -120,10 +120,10 @@ If you have a setup for developing the driver in an editor other than the ones l
120120
1. Ensure your code passes both the linter and the formatter.
121121
1. Make sure your code builds and passes all tests on:
122122
- [Travis](https://travis-ci.org/mongodb/mongo-swift-driver). Every time you push to GitHub or open a pull request, it will trigger a new build, which includes running the linter, formatter, and basic tests.
123-
- (If you work at MongoDB) [Evergreen](https://evergreen.mongodb.com/waterfall/mongo-swift-driver) - Our Evergreen matrix tests a variety of MongoDB configurations, operating systems, and Swift language versions, and provides a way to more robustly test the driver. A new Evergreen build is automatically triggered for every commit to master, but for more complex pull requests it's a good idea to run patches on Evergreen before merging.
124-
1. Open a pull request on the repository. Make sure you have rebased your branch onto the latest commits on `master`.
123+
- (If you work at MongoDB) [Evergreen](https://evergreen.mongodb.com/waterfall/mongo-swift-driver) - Our Evergreen matrix tests a variety of MongoDB configurations, operating systems, and Swift language versions, and provides a way to more robustly test the driver. A new Evergreen build is automatically triggered for every commit to `main`, but for more complex pull requests it's a good idea to run patches on Evergreen before merging.
124+
1. Open a pull request on the repository. Make sure you have rebased your branch onto the latest commits on `main`.
125125
1. Go through code review to get the team's approval on your changes. (See the next section on [Code Review](#code-review) for more details on this process.) Once you get the required approvals and your code passes all tests:
126-
1. Rebase on master again if needed.
126+
1. Rebase on `main` again if needed.
127127
1. Rerun tests.
128128
1. Squash all commits into a single, descriptive commit method, formatted as: `TICKET-NUMBER: Description of changes`. For example, `SWIFT-30: Implement WriteConcern type`.
129129
1. Merge it, or if you don't have permissions, ask someone to merge it for you.

Guides/Multithreaded-Usage.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,4 +16,4 @@ Each `MongoClient` uses its own background thread to monitor the MongoDB topolog
1616
**In order to share the connection pool across threads and minimize the number of background monitoring threads, we recommend sharing `MongoClient`s across threads.**
1717

1818
## Usage With Server-side Swift Frameworks
19-
See the [`Examples/`](https://github.com/mongodb/mongo-swift-driver/tree/master/Examples) directory in the driver GitHub repository for examples of how to integrate the driver in multithreaded frameworks.
19+
See the [`Examples/`](https://github.com/mongodb/mongo-swift-driver/tree/main/Examples) directory in the driver GitHub repository for examples of how to integrate the driver in multithreaded frameworks.

Package.resolved

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Package.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ let package = Package(
1212
dependencies: [
1313
.package(url: "https://github.com/Quick/Nimble.git", .upToNextMajor(from: "8.0.0")),
1414
.package(url: "https://github.com/apple/swift-nio", .upToNextMajor(from: "2.15.0")),
15-
.package(url: "https://github.com/mongodb/swift-bson", .branch("master"))
15+
.package(url: "https://github.com/mongodb/swift-bson", .branch("main"))
1616
],
1717
targets: [
1818
.target(name: "MongoSwift", dependencies: ["CLibMongoC", "NIO", "NIOConcurrencyHelpers", "SwiftBSON",]),

README.md

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
1-
[![Build Status](https://travis-ci.org/mongodb/mongo-swift-driver.svg?branch=master)](https://travis-ci.org/mongodb/mongo-swift-driver)
2-
[![Code Coverage](https://codecov.io/gh/mongodb/mongo-swift-driver/branch/master/graph/badge.svg)](https://codecov.io/gh/mongodb/mongo-swift-driver/branch/master)
3-
[![sswg:sandbox|94x20](https://img.shields.io/badge/sswg-sandbox-lightgrey.svg)](https://github.com/swift-server/sswg/blob/master/process/incubation.md#sandbox-level)
1+
[![Code Coverage](https://codecov.io/gh/mongodb/mongo-swift-driver/branch/main/graph/badge.svg)](https://codecov.io/gh/mongodb/mongo-swift-driver/branch/main)
2+
[![sswg:sandbox|94x20](https://img.shields.io/badge/sswg-sandbox-lightgrey.svg)](https://github.com/swift-server/sswg/blob/main/process/incubation.md#sandbox-level)
43

54
# MongoSwift
65
The official [MongoDB](https://www.mongodb.com/) driver for Swift applications on macOS and Linux.
@@ -191,11 +190,11 @@ all available. However, runtime guarantees are not yet met for many of these
191190
methods.
192191

193192
### Usage With Kitura, Vapor, and Perfect
194-
The `Examples/` directory contains sample projects that use the driver with [Kitura](https://github.com/mongodb/mongo-swift-driver/tree/master/Examples/KituraExample), [Vapor](https://github.com/mongodb/mongo-swift-driver/tree/master/Examples/ComplexVaporExample), and [Perfect](https://github.com/mongodb/mongo-swift-driver/tree/master/Examples/PerfectExample).
193+
The `Examples/` directory contains sample projects that use the driver with [Kitura](https://github.com/mongodb/mongo-swift-driver/tree/main/Examples/KituraExample), [Vapor](https://github.com/mongodb/mongo-swift-driver/tree/main/Examples/ComplexVaporExample), and [Perfect](https://github.com/mongodb/mongo-swift-driver/tree/main/Examples/PerfectExample).
195194

196195
Please note that the driver is built using SwiftNIO 2, and therefore is incompatible with frameworks built upon SwiftNIO 1. SwiftNIO 2 is used as of Vapor 4.0 and Kitura 2.5.
197196

198197
## Development Instructions
199198

200-
See our [development guide](https://github.com/mongodb/mongo-swift-driver/blob/master/Guides/Development.md) for instructions for building and testing the driver.
199+
See our [development guide](https://github.com/mongodb/mongo-swift-driver/blob/main/Guides/Development.md) for instructions for building and testing the driver.
201200

Sources/MongoSwift/ChangeStreamOptions.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ public struct ChangeStreamOptions: Codable {
5353
* to receive notifications even after an invalidate event (e.g. it will allow watching a collection that has
5454
* been dropped and recreated).
5555
* - Note: The server will report an error if `startAfter` and `resumeAfter` are both specified.
56-
* - SeeAlso: https://docs.mongodb.com/master/changeStreams/#change-stream-start-after
56+
* - SeeAlso: https://docs.mongodb.com/manual/changeStreams/#change-stream-start-after
5757
*/
5858
public var startAfter: ResumeToken?
5959

Sources/MongoSwift/ReadConcern.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ public struct ReadConcern: Codable {
1919
public static let majority = ReadConcern("majority")
2020

2121
/// Snapshot ReadConcern.
22-
/// - SeeAlso: https://docs.mongodb.com/master/reference/read-concern-snapshot/
22+
/// - SeeAlso: https://docs.mongodb.com/manual/reference/read-concern-snapshot/
2323
public static let snapshot = ReadConcern("snapshot")
2424

2525
/// Server default ReadConcern.

0 commit comments

Comments
 (0)