Skip to main content

revert

Usage

➜  ~ mprove revert -h
Revert (reset) repo to the state of a last commit or Remote repo, validate BlockML for selected env

━━━ Usage ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

$ mprove revert

━━━ Options ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

--to #0 (required, "last-commit" or "remote")
--project-id #0 (required) Project Id
--repo #0 (required, "dev" or "production")
--branch #0 (required) Git Branch
--env #0 (required) Environment
--get-errors (default false), show validation errors in output
--get-repo (default false), show repo in output
--json (default false)
--env-file-path #0 (optional) Path to ".env" file

━━━ Examples ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

Revert Dev repo to the state of Remote repo, validate BlockML for env prod
$ mprove revert --to remote --project-id DXYE72ODCP5LWPWH2EXQ --repo dev --branch main --env prod

Revert Production repo to the state of a last commit, validate BlockML for env prod
$ mprove revert --to last-commit --project-id DXYE72ODCP5LWPWH2EXQ --repo production --branch main --env prod

Example Output

➜  ~ mprove revert \
--to remote \
--env-file-path ~/mprove/.env \
--project-id DXYE72ODCP5LWPWH2EXQ \
--repo dev \
--branch main \
--env prod

message: Reverted repo state to remote
validationErrorsTotal: 0
url: https://cloud.mprove.io/org/AWNCAHWLFQTQJYCH3ZSE/project/DXYE72ODCP5LWPWH2EXQ/repo/XWZVQJLVR3NZJTBB4ZA6/branch/main/env/prod/files