-
Notifications
You must be signed in to change notification settings - Fork 20
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 #120 from citelao/dev
13.7
- Loading branch information
Showing
11 changed files
with
124 additions
and
25 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
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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Binary file not shown.
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,36 @@ | ||
<?php | ||
// Check the version string to ensure we've updated it everywhere! | ||
mb_internal_encoding("UTF-8"); | ||
date_default_timezone_set('America/New_York'); | ||
ini_set("display_errors", "stderr"); | ||
|
||
use OhAlfred\OhAlfred; | ||
require 'vendor/autoload.php'; | ||
|
||
$alfred = new OhAlfred(false /* catch_errors */); | ||
|
||
// Check CHANGELOG | ||
$changelog_filename = $alfred->workflow() . "CHANGELOG.md"; | ||
$changelog = file_get_contents($changelog_filename); | ||
$count = preg_match('/##\W*v?([\d.]*)/', $changelog, $matches); | ||
$changelog_version = $matches[1]; | ||
|
||
// Check `info.plist` | ||
$plist_version = $alfred->plist($alfred->workflow() . "info", "version"); | ||
|
||
// Check README | ||
$readme_filename = $alfred->workflow() . "README.md"; | ||
$readme = file_get_contents($readme_filename); | ||
$count = preg_match_all('/(\d+(?:\.\d+){2})/', $readme, $matches); | ||
$potential_readme_version = $matches[0]; | ||
|
||
// Compare results | ||
if($changelog_version != $plist_version || !in_array($changelog_version, $potential_readme_version)) { | ||
fwrite(STDERR, "Version mismatch! One or more versions are not in sync:\n"); | ||
fwrite(STDERR, "\t" . $changelog_version . " - CHANGELOG (expected version)\n"); | ||
fwrite(STDERR, "\t" . $plist_version . " - plist latest version\n"); | ||
foreach ($potential_readme_version as $ver) { | ||
fwrite(STDERR, "\t" . $ver . " - potential README version\n"); | ||
} | ||
exit(1); | ||
} |
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,25 @@ | ||
#!/bin/bash | ||
|
||
# https://docs.travis-ci.com/user/multi-os/ | ||
if [[ $TRAVIS_OS_NAME == 'osx' ]]; then | ||
# update & tap PHP! | ||
brew update | ||
brew tap homebrew/php | ||
|
||
case "${PHPENV}" in | ||
php55) | ||
brew install php55 | ||
;; | ||
php56) | ||
brew install php56 | ||
;; | ||
php70) | ||
brew install php70 | ||
;; | ||
esac | ||
|
||
# install Composer | ||
# https://github.com/phpmyadmin/phpmyadmin/commit/9ecda4175b6c19c781cf23254da151bfa15eb81a#diff-354f30a63fb0907d4ad57269548329e3 | ||
curl https://getcomposer.org/installer | php | ||
ln -s $PWD/composer.phar /usr/local/bin/composer | ||
fi |
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