Browse Source

cli: add short alias for build and test commands (#1823)

Blas Rodriguez Irizar 3 years ago
parent
commit
cb4549fdf3
2 changed files with 3 additions and 0 deletions
  1. 1 0
      CHANGELOG.md
  2. 2 0
      cli/src/lib.rs

+ 1 - 0
CHANGELOG.md

@@ -17,6 +17,7 @@ The minor version will be incremented upon a breaking change and the patch versi
 * cli: Add compilation optimizations to cli template ([#1807](https://github.com/project-serum/anchor/pull/1807)).
 * cli: `build` now adds docs to idl. This can be turned off with `--no-docs` ([#1561](https://github.com/project-serum/anchor/pull/1561)).
 * lang: Add `PartialEq` and `Eq` for `anchor_lang::Error` ([#1544](https://github.com/project-serum/anchor/pull/1544)).
+* cli: Add `b` and `t` aliases for `build` and `test` respectively ([#1823](https://github.com/project-serum/anchor/pull/1823)).
 
 ### Fixes
 

+ 2 - 0
cli/src/lib.rs

@@ -71,6 +71,7 @@ pub enum Command {
         no_git: bool,
     },
     /// Builds the workspace.
+    #[clap(name = "build", alias = "b")]
     Build {
         /// Output directory for the IDL.
         #[clap(short, long)]
@@ -157,6 +158,7 @@ pub enum Command {
         )]
         cargo_args: Vec<String>,
     },
+    #[clap(name = "test", alias = "t")]
     /// Runs integration tests against a localnetwork.
     Test {
         /// Use this flag if you want to run tests against previously deployed