Skip to content

Commit

Permalink
Reintroduced prerelease installation instructions
Browse files Browse the repository at this point in the history
  • Loading branch information
1ec5 committed Oct 29, 2021
1 parent 2adc568 commit 2d8bad1
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,20 +16,26 @@ Specify the following dependency in your [Carthage](https://github.com/Carthage/
```cartfile
# Latest stable release
github "mapbox/mapbox-directions-swift" ~> 2.0
# Latest prerelease
github "mapbox/mapbox-directions-swift" "v2.0.0"
```

Or in your [CocoaPods](http://cocoapods.org/) Podfile:

```podspec
# Latest stable release
pod 'MapboxDirections', '~> 2.0'
# Latest prerelease
pod 'MapboxDirections', :git => 'https://github.com/mapbox/mapbox-directions-swift.git', :tag => 'v2.0.0'
```

Or in your [Swift Package Manager](https://swift.org/package-manager/) Package.swift:

```swift
// Latest stable release
.package(name: "MapboxDirections", url: "https://github.com/mapbox/mapbox-directions-swift.git", from: "2.0.0")
// Latest prerelease
.package(name: "MapboxDirections", url: "https://github.com/mapbox/mapbox-directions-swift.git", .exact("2.0.0"))
```

Then `import MapboxDirections`.
Expand Down
3 changes: 1 addition & 2 deletions scripts/update-version.sh
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,7 @@ if [[ $SHORT_VERSION == $SEM_VERSION && $SHORT_VERSION == *.0 ]]; then
sed -i '' -E "s/~> *[^']+/~> ${MINOR_VERSION}/g; s/.git\", from: \"*[^\"]+/.git\", from: \"${SEM_VERSION}/g" README.md
elif [[ $SHORT_VERSION != $SEM_VERSION ]]; then
step "Updating readmes to version ${SEM_VERSION}"
sed -i '' -E "s/:tag => 'v[^']+'/:tag => 'v${SEM_VERSION}'/g; s/'MapboxDirections-pre', *'[^']+'/'MapboxDirections-pre', '${SEM_VERSION}'/g; s/\"mapbox\/mapbox-directions-swift\" \"v[^\"]+\"/\"mapbox\/mapbox-directions-swift\" \"v${SEM_VERSION}\"/g;" README.md
sed -i '' -e ":a" -e "N" -e "\$!ba" -e "s/from: \"[^\"]*/from: \"${SEM_VERSION}/2" README.md
sed -i '' -E "s/:tag => 'v[^']+'/:tag => 'v${SEM_VERSION}'/g; s/'MapboxDirections-pre', *'[^']+'/'MapboxDirections-pre', '${SEM_VERSION}'/g; s/\"mapbox\/mapbox-directions-swift\" \"v[^\"]+\"/\"mapbox\/mapbox-directions-swift\" \"v${SEM_VERSION}\"/g; s/\.exact\\(\"*[^\"]+/.exact(\"${SEM_VERSION}/g" README.md
fi

step "Updating copyright year to ${YEAR}"
Expand Down

0 comments on commit 2d8bad1

Please sign in to comment.