Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a build script #154

Merged
merged 2 commits into from
Jan 4, 2017
Merged

Add a build script #154

merged 2 commits into from
Jan 4, 2017

Conversation

garrettmoon
Copy link
Collaborator

No description provided.

Copy link
Collaborator

@jparise jparise left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is essentially a Makefile. Use one instead?

@garrettmoon
Copy link
Collaborator Author

All the tutorials I'm seeing focus on compilation, build is probably a misnomer in this case, it really should be called tests.sh (will happily do this). Does it still make sense to use a makefile? Do you know where to find documentation that focuses on this aspect of a makefile? Everything I'm seeing focuses on the compilation aspect, i.e. here's a set of source files you need to compile for this step.

@jparise
Copy link
Collaborator

jparise commented Dec 21, 2016

It would look something like this (totally untested):

PLATFORM="platform=iOS Simulator,OS=10.1,name=iPhone 7"
SDK="iphonesimulator10.1"

.PHONY: all lint test carthage

lint:
    pod lib lint --allow-warnings

test:
     xcodebuild clean test -destination "$PLATFORM" -sdk "$SDK" -project tests/PINCache.xcodeproj -scheme PINCacheTests ONLY_ACTIVE_ARCH=NO CODE_SIGNING_REQUIRED=NO | xcpretty -t; test ${PIPESTATUS[0]} -eq 0

carthage:
    carthage build --no-skip-current

all: lint test carthage

... and then you would invoke different targets as make lint or make lint test or make all.

@garrettmoon garrettmoon merged commit 6a98774 into master Jan 4, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants