-
Notifications
You must be signed in to change notification settings - Fork 453
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'fr/fix-rename-step-id' of https://github.com/windmill-l…
…abs/windmill into fr/fix-rename-step-id
- Loading branch information
Showing
13 changed files
with
1,490 additions
and
103 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
#!/bin/bash | ||
set -eou pipefail | ||
|
||
# full pkg | ||
OUT_DIR="pkg" | ||
wasm-pack build --release --target web --out-dir $OUT_DIR --all-features \ | ||
-Z build-std=panic_abort,std -Z build-std-features=panic_immediate_abort | ||
|
||
# bun and deno | ||
OUT_DIR="pkg-ts" | ||
wasm-pack build --release --target web --out-dir $OUT_DIR --features "ts-parser" \ | ||
-Z build-std=panic_abort,std -Z build-std-features=panic_immediate_abort | ||
sed -i 's/"windmill-parser-wasm"/"windmill-parser-wasm-ts"/' $OUT_DIR/package.json | ||
|
||
# sql languages, graphql and bash/powershell, since they all use regex | ||
OUT_DIR="pkg-regex" | ||
wasm-pack build --release --target web --out-dir $OUT_DIR \ | ||
--features "sql-parser,graphql-parser,bash-parser" \ | ||
-Z build-std=panic_abort,std -Z build-std-features=panic_immediate_abort | ||
sed -i 's/"windmill-parser-wasm"/"windmill-parser-wasm-regex"/' $OUT_DIR/package.json | ||
|
||
# python | ||
OUT_DIR="pkg-py" | ||
wasm-pack build --release --target web --out-dir $OUT_DIR --features "py-parser" \ | ||
-Z build-std=panic_abort,std -Z build-std-features=panic_immediate_abort | ||
sed -i 's/"windmill-parser-wasm"/"windmill-parser-wasm-py"/' $OUT_DIR/package.json | ||
|
||
# go | ||
OUT_DIR="pkg-go" | ||
wasm-pack build --release --target web --out-dir $OUT_DIR --features "go-parser" \ | ||
-Z build-std=panic_abort,std -Z build-std-features=panic_immediate_abort | ||
sed -i 's/"windmill-parser-wasm"/"windmill-parser-wasm-go"/' $OUT_DIR/package.json | ||
|
||
# php | ||
OUT_DIR="pkg-php" | ||
wasm-pack build --release --target web --out-dir $OUT_DIR --features "php-parser" \ | ||
-Z build-std=panic_abort,std -Z build-std-features=panic_immediate_abort | ||
sed -i 's/"windmill-parser-wasm"/"windmill-parser-wasm-php"/' $OUT_DIR/package.json | ||
|
||
# rust | ||
OUT_DIR="pkg-rust" | ||
wasm-pack build --release --target web --out-dir $OUT_DIR --features "rust-parser" \ | ||
-Z build-std=panic_abort,std -Z build-std-features=panic_immediate_abort | ||
sed -i 's/"windmill-parser-wasm"/"windmill-parser-wasm-rust"/' $OUT_DIR/package.json |
126 changes: 126 additions & 0 deletions
126
backend/parsers/windmill-parser-wasm/lib/windmill_parser_wasm.generated.d.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,126 @@ | ||
// deno-lint-ignore-file | ||
// deno-fmt-ignore-file | ||
|
||
export interface InstantiateResult { | ||
instance: WebAssembly.Instance; | ||
exports: { | ||
parse_deno: typeof parse_deno; | ||
parse_outputs: typeof parse_outputs; | ||
parse_ts_imports: typeof parse_ts_imports; | ||
parse_bash: typeof parse_bash; | ||
parse_powershell: typeof parse_powershell; | ||
parse_go: typeof parse_go; | ||
parse_python: typeof parse_python; | ||
parse_sql: typeof parse_sql; | ||
parse_mysql: typeof parse_mysql; | ||
parse_bigquery: typeof parse_bigquery; | ||
parse_snowflake: typeof parse_snowflake; | ||
parse_mssql: typeof parse_mssql; | ||
parse_db_resource: typeof parse_db_resource; | ||
parse_graphql: typeof parse_graphql; | ||
parse_php: typeof parse_php; | ||
parse_rust: typeof parse_rust | ||
}; | ||
} | ||
|
||
/** Gets if the Wasm module has been instantiated. */ | ||
export function isInstantiated(): boolean; | ||
|
||
/** Options for instantiating a Wasm instance. */ | ||
export interface InstantiateOptions { | ||
/** Optional url to the Wasm file to instantiate. */ | ||
url?: URL; | ||
/** Callback to decompress the raw Wasm file bytes before instantiating. */ | ||
decompress?: (bytes: Uint8Array) => Uint8Array; | ||
} | ||
|
||
/** Instantiates an instance of the Wasm module returning its functions. | ||
* @remarks It is safe to call this multiple times and once successfully | ||
* loaded it will always return a reference to the same object. */ | ||
export function instantiate(opts?: InstantiateOptions): Promise<InstantiateResult["exports"]>; | ||
|
||
/** Instantiates an instance of the Wasm module along with its exports. | ||
* @remarks It is safe to call this multiple times and once successfully | ||
* loaded it will always return a reference to the same object. */ | ||
export function instantiateWithInstance(opts?: InstantiateOptions): Promise<InstantiateResult>; | ||
|
||
/** | ||
* @param {string} code | ||
* @returns {string} | ||
*/ | ||
export function parse_deno(code: string): string; | ||
/** | ||
* @param {string} code | ||
* @returns {string} | ||
*/ | ||
export function parse_outputs(code: string): string; | ||
/** | ||
* @param {string} code | ||
* @returns {string} | ||
*/ | ||
export function parse_ts_imports(code: string): string; | ||
/** | ||
* @param {string} code | ||
* @returns {string} | ||
*/ | ||
export function parse_bash(code: string): string; | ||
/** | ||
* @param {string} code | ||
* @returns {string} | ||
*/ | ||
export function parse_powershell(code: string): string; | ||
/** | ||
* @param {string} code | ||
* @returns {string} | ||
*/ | ||
export function parse_go(code: string): string; | ||
/** | ||
* @param {string} code | ||
* @returns {string} | ||
*/ | ||
export function parse_python(code: string): string; | ||
/** | ||
* @param {string} code | ||
* @returns {string} | ||
*/ | ||
export function parse_sql(code: string): string; | ||
/** | ||
* @param {string} code | ||
* @returns {string} | ||
*/ | ||
export function parse_mysql(code: string): string; | ||
/** | ||
* @param {string} code | ||
* @returns {string} | ||
*/ | ||
export function parse_bigquery(code: string): string; | ||
/** | ||
* @param {string} code | ||
* @returns {string} | ||
*/ | ||
export function parse_snowflake(code: string): string; | ||
/** | ||
* @param {string} code | ||
* @returns {string} | ||
*/ | ||
export function parse_mssql(code: string): string; | ||
/** | ||
* @param {string} code | ||
* @returns {string | undefined} | ||
*/ | ||
export function parse_db_resource(code: string): string | undefined; | ||
/** | ||
* @param {string} code | ||
* @returns {string} | ||
*/ | ||
export function parse_graphql(code: string): string; | ||
/** | ||
* @param {string} code | ||
* @returns {string} | ||
*/ | ||
export function parse_php(code: string): string; | ||
/** | ||
* @param {string} code | ||
* @returns {string} | ||
*/ | ||
export function parse_rust(code: string): string; |
Oops, something went wrong.