Closed Julio-de-Leon closed 6 months ago
Take a look at electron-edge-js readme, there are some examples for packaging as well as references to similar issues that people had.
I tried to use electron-builder to package the application, but I still can't make it work. After generating the .exe I double click it and after the installation it produces an error.
I'm not sure what I'm doing wrong. This is my package.json
{
"name": "electron-edge-js-quick-start",
"version": "1.0.0",
"description": "Minimal Electron application using `electron-edge-js` with .NET",
"main": "main.js",
"scripts": {
"start": "electron --core .",
"start:core": "electron --core .",
"start:standard": "electron --standard .",
"app:dir": "electron-builder --dir",
"app:dist": "electron-builder",
"postinstall": "electron-builder install-app-deps"
},
"keywords": [
"Electron",
"quick",
"start",
"tutorial",
"demo",
"Edge",
"Edge.js"
],
"license": "MIT",
"devDependencies": {
"electron": "^30.0.2",
"electron-builder": "^24.13.3"
},
"build": {
"appId": "your.id"
},
"dependencies": {
"electron-edge-js": "^30.0.1"
}
}
This is my QuickStart.Core.csproj
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net7.0</TargetFramework>
<PreserveCompilationContext>true</PreserveCompilationContext>
<CopyLocalLockFileAssemblies>true</CopyLocalLockFileAssemblies>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Newtonsoft.Json" Version="13.0.3" />
<PackageReference Include="Microsoft.CodeAnalysis" Version="4.9.2" />
<PackageReference Include="Microsoft.CSharp" Version="4.5.0" />
<PackageReference Include="Microsoft.DotNet.InternalAbstractions" Version="1.0.0" />
<PackageReference Include="Microsoft.Extensions.DependencyModel" Version="8.0.0" />
</ItemGroup>
<ItemGroup>
<Reference Include="EmailSender_Outlook">
<HintPath>.\bin\Debug\net7.0\EmailSender_Outlook.dll</HintPath>
<Private>true</Private>
</Reference>
</ItemGroup>
<ItemGroup>
<Reference Include="EdgeJs">
<HintPath>..\..\node_modules\electron-edge-js\lib\bootstrap\bin\Release\net6.0\EdgeJs.dll</HintPath>
<Private>true</Private>
</Reference>
</ItemGroup>
<ItemGroup>
<Compile Include="..\shared\LocalMethods.cs">
<Link>LocalMethods.cs</Link>
</Compile>
</ItemGroup>
</Project>
Did you take a look at packaging instructions that I linked electron-edge-js?
I've been tinkering with the electron-edge-js-quick-start since yesterday, but I'm unable to create a package. This is what I do:
My next step is to package the application. I followed the instructions on electron js website. https://www.electronjs.org/docs/latest/tutorial/tutorial-packaging
It doesn't work and it stops without error log. It always stop on preparing native dependencies.
windows 10 dotnet version: 7.0.408 node version: 20.12.2 npm version: 8.12.1
Any help is appreciated. Thank you so much.