Skip to content

Releases: captainhookphp/captainhook

5.23.0

12 Apr 10:55
5.23.0
08d90e4
Compare
Choose a tag to compare

Changes

  • Add WSL run-mode support (by Christoph Kappestein)
{
  "config": {
    "run": {
      "mode": "wsl"
    }
  }
  ...
}

Full Changelog: 5.23.0...5.23.0

5.22.2

05 Apr 11:30
5.22.2
6c519d1
Compare
Choose a tag to compare

Changes

  • issue #242 - Prevent PHPScoper from replacing action namespaces
  • Remove completion commands
  • Cleanup line handling

Full Changelog: 5.22.1...5.22.2

5.22.1

06 Mar 13:19
5.22.1
dbd4dd6
Compare
Choose a tag to compare

Changes

  • Add --only-disabled option to uninstall command

Now captainhook uninstall --only-disabled can be used to remove disabled hooks.

5.22.0

06 Mar 11:05
5.22.0
9185d04
Compare
Choose a tag to compare

Changes

  • Convert hook stdIn to cmd option
  • Add confirmation action
  • Hook script compatibility check
  • BlockFixupCommits action got some verbose output

⚠️ Attention ⚠️

This version contains a bigger change that requires to update the generated hook scripts.
This is necessary because the decision was made to convert the original hook stdIn to a cmd option --input to allow prompting the user for input for all hooks as long as a tty is available.

A new Action was added to ask users if they want to continue with the current git operation. The action uses event handler to make sure that users are only bothered to input something if the hook succeeds. Both options are optional and can be skipped.

            {
                "action": "\\CaptainHook\\App\\Hook\\UserInput\\AskConfirmation",
                "options": {
                    "message": "Do you really want it? [yes|no]",
                    "default": true
                },
                "config": {
                    "label": "User confirmation!"
                }
            }

Short note: This action does not work in GUI tools like Sourcetree, or PHPStorm because they fail to forward the tty properly.

User input should be possible for all hooks now as long as you use run-mode shell (default) or docker. In run-mode php user input does not work for pre-push and post-rewrite because data can not be read from stdIn and tty at the same time and both hooks require stdIn data to work properly.

5.21.2

23 Jan 13:11
5.21.2
f0911f6
Compare
Choose a tag to compare

Changes

  • Fix double '..' revision range for {$BRANCH_FILES} placeholder

5.21.1

23 Jan 12:35
5.21.1
b50216b
Compare
Choose a tag to compare

Changes

  • Allow skipping options for Branch\Files Condition

5.21.0

23 Jan 11:05
5.21.0
5d1926b
Compare
Choose a tag to compare

Changes

  • Revert reflog fallback for {$CHANGED_FILES} introduced in 5.20.0
  • Add new Branch\Files condition
  • Add new {$BRANCH_FILES} placeholder

5.20.2

22 Jan 15:39
5.20.2
e485ec7
Compare
Choose a tag to compare

Changes

  • Add conditions to check current branch by regex inspired by @Eydamos ;)
  • Add On and NotOn branch conditions

The Condition\OnBranch condition is now deprecated and should be replaced with Condition\Branch\On.
Full list of Conditions can be found here

5.20.1

22 Jan 12:13
5.20.1
be5608c
Compare
Choose a tag to compare

Changes

  • Add IntegrateBeforePush action
  • Add proper filter settings to not list deleted files
  • Properly check the detected ranges
  • Split debug action into Success and Failure

5.20.0

19 Jan 19:50
5.20.0
cebfe57
Compare
Choose a tag to compare

Changes

  • Refactor and optimize changeset discovery huge thanks to @Eydamos
  • Output executed cli command anyway in verbose mode
  • Fix branch extraction
  • Catch condition exceptions

🐛 Bugfixes

#233 #234