Skip to content

Add documentation on rollback command #79

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Dec 5, 2015
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 18 additions & 2 deletions cli/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

CodePush is a cloud service that enables Cordova and React Native developers to deploy mobile app updates directly to their users' devices. It works by acting as a central repository that developers can publish updates to (JS, HTML, CSS and images), and that apps can query for updates from (using provided client SDKs for [Cordova](http://github.com/Microsoft/cordova-plugin-code-push) and [React Native](http://github.com/Microsoft/react-native-code-push)). This allows you to have a more deterministic and direct engagement model with your userbase, when addressing bugs and/or adding small features that don't require you to re-build a binary and re-distribute it through the respective app stores.

![CodePush CLI](https://cloud.githubusercontent.com/assets/116461/11233671/1d0329ae-8d75-11e5-8cf4-781109ca83b8.png)
![CodePush CLI](https://cloud.githubusercontent.com/assets/696206/11604752/543b5f08-9aa5-11e5-994b-fb1642643f5f.PNG)

## Installation

Expand Down Expand Up @@ -184,12 +184,28 @@ code-push promote <appName> <sourceDeploymentName> <destDeploymentName>
code-push promote MyApp Staging Production
```

The release produced by a promotion will be annotated in the output of the `deployment history` command.

## Rolling back undesired updates

If you release an update that is broken or contains unintended features, it is easy to roll it back using the `rollback` command:

```
code-push rollback MyApp Production
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It seems obvious, but could we add a "formal" example of the args here like we do for the promote command? (E.g. "code-push rollback ")

```

This has the effect of issuing another release with the same contents and metadata as the version prior to the latest one. Note that this means that issuing a second consecutive `rollback` command simply cancels out the first one.

The release produced by a rollback will be annotated in the output of the `deployment history` command.

## Viewing release history

You can view a history of the 50 most recent releases for a specific app deployment (including promotions) using the following command:
You can view a history of the 50 most recent releases for a specific app deployment using the following command:

```
code-push deployment history <appName> <deploymentName>
```

![Deployment History](https://cloud.githubusercontent.com/assets/696206/11604911/2ef6d044-9aa8-11e5-84a3-5b04e4929b35.png)

*NOTE: The history command can also be run using the "h" alias*