wp-parse-api 0.9.0

Minimal plugin API for wp-lang data pipelines and parser components
Documentation
extern mod rust,ver,git { path = "./_gal/mods";  }

mod envs  {
   env _common  : rust_env.init   {
    root      = ".";
    target_name = "";
    prj_key   = "wp-open-api" ;

  }

  #[usage(desp="use debug ",color="blue")]
  env debug :  _common,rust_env.debug {
  }
  #[usage(desp="use debug ",color="blue")]
  env release :  _common,rust_env.release{
  }


  #[usage(desp="default mamcos", color="green")]
  env default    : envs._common,debug;
}

mod main  {
      bld_bins = "target/${ENV_BUILD_NAME}" ;
      rls_bins = "target/release" ;
      HOME_BIN = "${HOME}/bin" ;

    #[auto_load(entry)]
    flow __into | conf {
        DIST_REPO = "unkonw";
        if defined(${GXL_OS_SYS}) {
             gx.echo (  "${GXL_OS_SYS} is defined " )
        }
        if ${GXL_OS_SYS} =* "arm64_macos_*" {
            DIST_REPO = "macos";
        } else if ${GXL_OS_SYS} =* "x86_64_ubuntu*" {
            DIST_REPO = "ubuntu22";
        }
        else {
            DIST_REPO = "other";
        }

    }
    #[task(name="config")]
    flow conf  {
    }

  #[task(name="${ENV_PRJ_KEY}@build")]
  flow ver.use | conf | rust_flow.build | @build  {
      gx.echo(  "${MAIN_HOME_BIN}" );
      //os.path (  "${MAIN_HOME_BIN}" );
  }
  #[usage(desp="lint code")]
  flow lint | rust_flow.lint {} ;

  #[task(name="test")]
  flow build  |   @test  {
    gx.cmd ( "cargo test --all ${ENV_BUILD_FLAG}", log : "1" , out:"true"  );
  }

}