Skip to content

Commit

Permalink
fix(update): Skip logs starting with (chore) (#4800)
Browse files Browse the repository at this point in the history
* fix(update): Skip logs starting with `(chore)`

* Update CHANGELOG.md
  • Loading branch information
rashil2000 authored Mar 10, 2022
1 parent a66a086 commit 476b507
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

- **installed:** If no `$global`, check both local and global installed ([#4798](https://github.com/ScoopInstaller/Scoop/issues/4798))
- **scoop-prefix:** Fix typo that breaks global installed apps ([#4795](https://github.com/ScoopInstaller/Scoop/issues/4795))
- **update:** Skip logs starting with `(chore)` ([#4800](https://github.com/ScoopInstaller/Scoop/issues/4800))

### Code Refactoring

Expand Down
4 changes: 2 additions & 2 deletions libexec/scoop-update.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ function update_scoop() {

$res = $lastexitcode
if ($show_update_log) {
Invoke-Expression "git -C '$currentdir' --no-pager log --no-decorate --grep='^chore' --invert-grep --format='tformat: * %C(yellow)%h%Creset %<|(72,trunc)%s %C(cyan)%cr%Creset' '$previousCommit..HEAD'"
Invoke-Expression "git -C '$currentdir' --no-pager log --no-decorate --grep='^(chore)' --invert-grep --format='tformat: * %C(yellow)%h%Creset %<|(72,trunc)%s %C(cyan)%cr%Creset' '$previousCommit..HEAD'"
}

if ($res -ne 0) {
Expand Down Expand Up @@ -148,7 +148,7 @@ function update_scoop() {
$previousCommit = (Invoke-Expression "git -C '$bucketLoc' rev-parse HEAD")
git_cmd -C "`"$bucketLoc`"" pull -q
if ($show_update_log) {
Invoke-Expression "git -C '$bucketLoc' --no-pager log --no-decorate --grep='^chore' --invert-grep --format='tformat: * %C(yellow)%h%Creset %<|(72,trunc)%s %C(cyan)%cr%Creset' '$previousCommit..HEAD'"
Invoke-Expression "git -C '$bucketLoc' --no-pager log --no-decorate --grep='^(chore)' --invert-grep --format='tformat: * %C(yellow)%h%Creset %<|(72,trunc)%s %C(cyan)%cr%Creset' '$previousCommit..HEAD'"
}
}

Expand Down

0 comments on commit 476b507

Please sign in to comment.