-
Notifications
You must be signed in to change notification settings - Fork 85
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #72 from contentful/improvement/readme
Improve README and github configuration
- Loading branch information
Showing
5 changed files
with
83 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
<!-- | ||
Please follow the instructions below before filing a new issue. | ||
Please ensure that you are at least on the newest minor version of the SDK. | ||
The minor version is delineated in the following example with an `x`: `0.x.11` | ||
There are many changes to the Swift language and Xcode that are not backwards compatible | ||
and versions of Swift < 3 and versions of Xcode < 8 are not supported by Contentful. | ||
Swift package manager is not yet supported. | ||
--> | ||
|
||
Fill in the following details, then delete this line before submitting. (To mark a checkbox change `- [ ]` to `- [x]`). | ||
> - contentful.swift version number: | ||
> - Xcode version number: | ||
> - Target operating system(s) and version number(s) | ||
- [ ] iOS: | ||
- [ ] tvOS: | ||
- [ ] watchOS: | ||
- [ ] macOS: | ||
> - Package manager: | ||
- [ ] Carthage | ||
- [ ] Cocoapods | ||
|
||
<!-- Enter your issue details below this comment. --> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,5 @@ | ||
|
||
|
||
## Development and versioning | ||
Development should be done with Xcode as a strict requirement of the project is that iOS, macOS, tvOS, and watchOS stay supported. This, in turn, means that development will be done on a Mac, and it is therefore suggested that [homebrew](https://brew.sh/) be installed. The `make setup_env` command will install or update the necessary brew packages required to work on the contentful.swift project (note that it will not install homebrew for you). | ||
|
||
One brew package that the project uses is [direnv](https://direnv.net/) which is used to consolidate all the places the SDK's version number must be injected to one place. Updating the version number before a future release should be done in the `.envrc` file in the root directory of the project. | ||
Development should be done with Xcode as a strict requirement of the project is that iOS, macOS, tvOS, and watchOS stay supported. This, in turn, means that development will be done on a Mac, and it is therefore required that [homebrew](https://brew.sh/) is installed. The `make setup_env` command will install or update the necessary brew packages required to work on the contentful.swift project (note that it will not install homebrew for you). | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
#!/bin/bash | ||
|
||
|
||
set -e # forward failure to the rest of the program | ||
|
||
which -s brew | ||
if [[ $? != 0 ]] ; then | ||
echo "ERROR: Homebrew must be installed on your machine in order to configure your environment" | ||
echo "for developing contentful.swift. Please visit https://brew.sh/ for installation instructions." | ||
exit 1 | ||
else | ||
brew update | ||
fi | ||
|
||
|
||
if ! brew ls --versions carthage > /dev/null; then | ||
echo "Installing carthage via homebrew" | ||
brew install carthage | ||
fi | ||
|
||
if ! brew ls --versions swiftlint > /dev/null; then | ||
echo "Installing swiftlint via homebrew" | ||
brew install swiftlint | ||
fi | ||
|
||
if ! brew ls --versions direnv > /dev/null; then | ||
echo "Installing direnv via homebrew" | ||
brew install direnv | ||
fi | ||
|
||
|
||
|
||
# Update carthage and swiftlint | ||
brew outdated carthage || brew upgrade carthage | ||
brew outdated swiftlint || brew upgrade swiftlint | ||
brew outdated direnv || brew upgrade direnv | ||
|
||
bundle install | ||
|