微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

错误命令失败,退出代码为 1yarn 在 windows 上启动

如何解决错误命令失败,退出代码为 1yarn 在 windows 上启动

我正在尝试在 Windows 上启动 React 项目。我的同事在 Mac 上,他们可以在 package.json 中使用以下脚本运行项目

static string variant_1()
{
    string str;

    try
    {
        str = "grrr";
    }
    finally
    {

    }

    return str; //no problem ?
}

static string variant_2()
{
    string str;

    try
    {
        str = "grrr";
    }
    catch (Exception ex)
    {

    }

    return str; //does not compile: `CS0165: Use of unassigned local variable`
}

对于Windows,我将其更改为

"scripts": {
    "start": "chmod +x ./env.sh && ./env.sh && cp env-config.js ./public/ && craco start","dev": "craco start","build": "craco build","test": "craco test","test-debug": "node --inspect-brk ./node_modules/jest/bin/jest.js --runInBand --watch","eject": "craco eject","styleguide": "styleguidist server","styleguide:build": "styleguidist build"
},

但我收到语法错误

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。