File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -2,12 +2,13 @@ language: objective-c
22osx_image : xcode8
33matrix :
44 include :
5- - env : BUILD=9.3
6- script : bundle exec rake ci:build[9.3]
7- - env : BUILD=latest
8- script : bundle exec rake ci:build[latest]
9- - env : BUILD=carthage
10- script : make carthage
5+ - env : VERSION=9.3
6+ - env : VERSION=latest
7+ - env : VERSION=carthage
8+ before_script :
9+ - bundle exec danger
10+ script :
11+ - make carthage
1112 after_script :
1213 - make documentation
1314cache :
@@ -21,6 +22,8 @@ install:
2122 - make install
2223before_script :
2324 - xcodebuild -workspace ICInputAccessory.xcworkspace -list
25+ script :
26+ - bundle exec rake ci:build[$VERSION]
2427notifications :
2528 email : false
2629 slack :
Original file line number Diff line number Diff line change 1+ #!/usr/bin/env ruby
2+
3+ # Sometimes it's a README fix, or something like that - which isn't relevant for
4+ # including in a project's CHANGELOG for example
5+ declared_trivial = pr_title . include? "#trivial"
6+
7+ # Make it more obvious that a PR is a work in progress and shouldn't be merged yet
8+ warn ( "PR is classed as Work in Progress" ) if pr_title . include? "[WIP]"
9+
10+ # Warn when there is a big PR
11+ warn ( "Big PR" ) if lines_of_code > 500
12+
13+ # Don't let testing shortcuts get into master by accident
14+ fail ( "fdescribe left in tests" ) if `grep -r fdescribe specs/` . length > 1
15+ fail ( "fit left in tests" ) if `grep -r "fit specs/ ` . length > 1
16+
17+ # Add a CHANGELOG entry for app changes
18+ if git . lines_of_code > 50 && !github . modified_files . include? ( "CHANGELOG.md" ) && !declared_trivial
19+ fail ( "Please update [CHANGELOG.md](https://github.com/polydice/ICInputAccessory/blob/develop/CHANGELOG.md)." )
20+ end
21+
22+ # Ensure a clean commits history
23+ if git . commits . any? { |c | c . message =~ /^Merge branch/ }
24+ fail ( 'Please rebase to get rid of the merge commits in this PR' )
25+ end
You can’t perform that action at this time.
0 commit comments