@@ -63745,7 +63745,7 @@ var tool_cache = __toESM(require_tool_cache(), 1);
63745
63745
var cache = __toESM(require_cache2(), 1);
63746
63746
var import_semver = __toESM(require_semver3(), 1);
63747
63747
import {existsSync, readFileSync as readFileSync3, chmodSync} from "fs";
63748
- import {join} from "path";
63748
+ import {join, dirname } from "path";
63749
63749
async function run() {
63750
63750
try {
63751
63751
checkPlatformCompatibility();
@@ -63780,7 +63780,10 @@ async function run() {
63780
63780
const installedPath = await installFlutterGen(version, cacheEnabled, cacheKey, cachePath);
63781
63781
core2.info(`FlutterGen installed: ${installedPath}`);
63782
63782
await makeExecutable(installedPath);
63783
- await execa("fluttergen", ["--version"], { stdio: "inherit" });
63783
+ const { stdout } = await execa("fluttergen", ["--version"]);
63784
+ if (stdout !== `FlutterGen v${version}`) {
63785
+ throw new Error(`commnad doesn't work as expected: ${stdout}`);
63786
+ }
63784
63787
core2.setOutput("version", version);
63785
63788
} catch (error2) {
63786
63789
if (error2 instanceof Error) {
@@ -63835,9 +63838,9 @@ async function installFlutterGen(version, cacheEnabled, cacheKey, cachePath) {
63835
63838
}
63836
63839
async function makeExecutable(installedPath) {
63837
63840
const fluttergenPath = join(installedPath, "fluttergen");
63838
- chmodSync(fluttergenPath, 755);
63839
- core2.addPath(installedPath );
63841
+ chmodSync(fluttergenPath, " 755" );
63842
+ core2.addPath(dirname(fluttergenPath) );
63840
63843
}
63841
63844
run();
63842
63845
63843
- //# debugId=2ECF789E3C76642064756E2164756E21
63846
+ //# debugId=882A08D3CC4BC75964756E2164756E21
0 commit comments