You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Scenario: At the moment we have 4 predefined hooks locations per action: 4 on pull and 4 on push. While we can order commands inside each location, we cannot change the order used to fire the locations.
Problem: we cannot coordinate operations. E.g.: if I want to receive a chat notification when a deploy is finished, I must use a hook inside after.femote location, because it's the last to be fired.
Solution: hooks definition in the movefile shuold be refactored to something like
group hooks by action; previous order must be honored in each group. Will ignore the group which is not for the current action.
group hooks by when; previous order must be honored in each group
run the resulting groups at the right time in order
Expected result: we'll be able to run hooks locally ore remotely using an arbitrary order. E.g: we'll be able to send a Ryver chat message after push using our local machine as the very last command.
Alternate YAML structure (more expressive?):
hooks:
push:
before:
- command: 'bash ./send_ryver_message.sh'where: local
- command: 'wp do something'where: remoteafter:
- command: 'wp do something'where: remote
- command: 'bash ./send_ryver_message.sh'where: localpull:
before:
after:
The goal of the alternative syntax is to have a more intuitive structure: with a flat structure is harder to understand what will be executed where and when, this way the only flat structure will be used where actually we want to have an arbitrary order.
The text was updated successfully, but these errors were encountered:
Scenario: At the moment we have 4 predefined hooks locations per action: 4 on
pull
and 4 onpush
. While we can order commands inside each location, we cannot change the order used to fire the locations.Problem: we cannot coordinate operations. E.g.: if I want to receive a chat notification when a deploy is finished, I must use a hook inside
after.femote
location, because it's the last to be fired.Solution: hooks definition in the movefile shuold be refactored to something like
this way Wordmove will
action
; previous order must be honored in each group. Will ignore the group which is not for the current action.when
; previous order must be honored in each groupExpected result: we'll be able to run hooks locally ore remotely using an arbitrary order. E.g: we'll be able to send a Ryver chat message after push using our local machine as the very last command.
Alternate YAML structure (more expressive?):
The goal of the alternative syntax is to have a more intuitive structure: with a flat structure is harder to understand what will be executed where and when, this way the only flat structure will be used where actually we want to have an arbitrary order.
The text was updated successfully, but these errors were encountered: