Skip to content

Commit

Permalink
fixed blt github release command
Browse files Browse the repository at this point in the history
  • Loading branch information
pookmish committed Jul 10, 2019
1 parent 5c5c740 commit 22852a3
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 11 deletions.
9 changes: 6 additions & 3 deletions blt/src/Commands/CircleCiCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -112,8 +112,11 @@ public function jobGithubRelease() {
* Array of change strings.
*/
protected function updateChangelog($version, array $changes = []) {
array_walk($changes, function (&$change) {
$change = '* ' . $change;
});
$divider = str_repeat('-', 80);
$this->taskChangelog(__DIR__ . '/docs/CHANGELOG.md')
$this->taskChangelog($this->getConfigValue('repo.root') . '/docs/CHANGELOG.md')
->setHeader("$version\n{$divider}\n_Release Date: " . date("Y-m-d") . "_\n\n")
->anchor("# HumSci")
->setBody(implode("\n", $changes))
Expand Down Expand Up @@ -146,9 +149,9 @@ protected function setVersions($version) {
if (strpos($module->getPath(), 'tests') !== FALSE) {
continue;
}
$info_file = Yaml::parseFile($module->getRealPath());
$info_file = Yaml::decode(file_get_contents($module->getRealPath()));
$info_file['version'] = $version;
file_put_contents($module->getRealPath(), Yaml::dump($info_file));
file_put_contents($module->getRealPath(), Yaml::encode($info_file));
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion blt/src/Commands/HumsciTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ protected function getGitHubInfo() {
* Last semver version.
*/
protected function getLastVersion() {
$profile_info = Yaml::decode($this->getConfigValue('docroot') . '/profiles/humsci/su_humsci_profile/su_humsci_profile.info.yml');
$profile_info = Yaml::decode(file_get_contents($this->getConfigValue('docroot') . '/profiles/humsci/su_humsci_profile/su_humsci_profile.info.yml'));
return $profile_info['version'];
}

Expand Down
9 changes: 5 additions & 4 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion tests/behat/features/install/content/BasicPage.feature
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ Feature: Install State Basic Page
And I wait 2 seconds
And I set window dimensions 1201 x 3001
Then I select "Medium (220×220)" from "Image Style"
And I fill in "Alternative text" with "Stanford Logo"
And I fill in "Alternate text" with "Stanford Logo"
Then I click the ".entity-select-dialog .form-actions button" element
And I wait for AJAX to finish
Then I press "Save"
Expand Down

0 comments on commit 22852a3

Please sign in to comment.