mirror of
https://github.com/mii443/wasmer.git
synced 2025-12-08 13:48:26 +00:00
Revert "Implement wasmer init and wasmer publish"
This commit is contained in:
@@ -11,7 +11,7 @@ use crate::commands::CreateObj;
|
||||
#[cfg(feature = "wast")]
|
||||
use crate::commands::Wast;
|
||||
use crate::commands::{
|
||||
Add, Cache, Config, Init, Inspect, List, Login, Publish, Run, SelfUpdate, Validate, Whoami,
|
||||
Add, Cache, Config, Inspect, List, Login, Run, SelfUpdate, Validate, Whoami,
|
||||
};
|
||||
use crate::error::PrettyError;
|
||||
use clap::{CommandFactory, ErrorKind, Parser};
|
||||
@@ -46,10 +46,6 @@ enum WasmerCLIOptions {
|
||||
/// Login into a wapm.io-like registry
|
||||
Login(Login),
|
||||
|
||||
/// Login into a wapm.io-like registry
|
||||
#[clap(name = "publish")]
|
||||
Publish(Publish),
|
||||
|
||||
/// Wasmer cache
|
||||
#[clap(subcommand)]
|
||||
Cache(Cache),
|
||||
@@ -139,10 +135,6 @@ enum WasmerCLIOptions {
|
||||
/// Inspect a WebAssembly file
|
||||
Inspect(Inspect),
|
||||
|
||||
/// Initializes a new wapm.toml file
|
||||
#[clap(name = "init")]
|
||||
Init(Init),
|
||||
|
||||
/// Run spec testsuite
|
||||
#[cfg(feature = "wast")]
|
||||
Wast(Wast),
|
||||
@@ -173,10 +165,8 @@ impl WasmerCLIOptions {
|
||||
Self::CreateObj(create_obj) => create_obj.execute(),
|
||||
Self::Config(config) => config.execute(),
|
||||
Self::Inspect(inspect) => inspect.execute(),
|
||||
Self::Init(init) => init.execute(),
|
||||
Self::List(list) => list.execute(),
|
||||
Self::Login(login) => login.execute(),
|
||||
Self::Publish(publish) => publish.execute(),
|
||||
#[cfg(feature = "wast")]
|
||||
Self::Wast(wast) => wast.execute(),
|
||||
#[cfg(target_os = "linux")]
|
||||
@@ -234,9 +224,10 @@ fn wasmer_main_inner() -> Result<(), anyhow::Error> {
|
||||
WasmerCLIOptions::Run(Run::from_binfmt_args())
|
||||
} else {
|
||||
match command.unwrap_or(&"".to_string()).as_ref() {
|
||||
"add" | "cache" | "compile" | "config" | "create-exe" | "help" | "inspect" | "init"
|
||||
| "run" | "self-update" | "validate" | "wast" | "binfmt" | "list" | "login"
|
||||
| "publish" => WasmerCLIOptions::parse(),
|
||||
"add" | "cache" | "compile" | "config" | "create-exe" | "help" | "inspect" | "run"
|
||||
| "self-update" | "validate" | "wast" | "binfmt" | "list" | "login" => {
|
||||
WasmerCLIOptions::parse()
|
||||
}
|
||||
_ => {
|
||||
WasmerCLIOptions::try_parse_from(args.iter()).unwrap_or_else(|e| {
|
||||
match e.kind() {
|
||||
|
||||
Reference in New Issue
Block a user