Add support for routines; state messages

This commit is contained in:
garrettmills
2020-04-15 09:11:10 -05:00
parent e401809ad5
commit 8319859828
36 changed files with 1146 additions and 22 deletions

View File

@@ -33,6 +33,13 @@ class CheckoutState extends AbstractGitState {
}
}
failure_message() {
return `The Git repo at "${this._config.path}" on host "${this._host.name}" is not checked out to the correct ref (${this._config.target}).`
}
check_message() {
return this.failure_message()
}
}
module.exports = exports = CheckoutState

View File

@@ -21,6 +21,13 @@ class CloneState extends AbstractGitState {
}
}
failure_message() {
return `Could not find the cloned Git repo at "${this._config.path}" on host "${this._host.name}."`
}
check_message() {
return this.failure_message()
}
}
module.exports = exports = CloneState

View File

@@ -26,6 +26,13 @@ class TagState extends AbstractGitState {
}
}
failure_message() {
return `The tag "${this._config.tag}" does not exist in the Git repo "${this._config.path}" on host "${this._host.name}."`
}
check_message() {
return this.failure_message()
}
}
module.exports = exports = TagState