Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
HendrikMennen committed Mar 14, 2024
1 parent b80dde5 commit e931be2
Show file tree
Hide file tree
Showing 4 changed files with 31 additions and 19 deletions.
21 changes: 21 additions & 0 deletions oneware-extension.json
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,27 @@
"url": "https://github.com/ProtopSolutions/OneWare.GhdlExtension/releases/download/0.7/OneWare_GhdlExtension_0.7_osx-arm64.zip"
}
]
},
{
"version": "0.8",
"targets": [
{
"target": "win-x64",
"url": "https://github.com/ProtopSolutions/OneWare.GhdlExtension/releases/download/0.8/OneWare_GhdlExtension_0.8_win-x64.zip"
},
{
"target": "linux-x64",
"url": "https://github.com/ProtopSolutions/OneWare.GhdlExtension/releases/download/0.8/OneWare_GhdlExtension_0.8_linux-x64.zip"
},
{
"target": "osx-x64",
"url": "https://github.com/ProtopSolutions/OneWare.GhdlExtension/releases/download/0.8/OneWare_GhdlExtension_0.8_osx-x64.zip"
},
{
"target": "osx-arm64",
"url": "https://github.com/ProtopSolutions/OneWare.GhdlExtension/releases/download/0.8/OneWare_GhdlExtension_0.8_osx-arm64.zip"
}
]
}
]
}
6 changes: 3 additions & 3 deletions src/OneWare.Ghdl/OneWare.Ghdl.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<Version>0.7</Version>
<Version>0.8</Version>
<TargetFramework>net8.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
Expand All @@ -15,8 +15,8 @@
</ItemGroup>

<ItemGroup>
<PackageReference Include="OneWare.Essentials" Version="0.4.1" Private="false" ExcludeAssets="runtime;Native"/>
<PackageReference Include="OneWare.UniversalFpgaProjectSystem" Version="0.16.1" Private="false" ExcludeAssets="runtime;Native"/>
<PackageReference Include="OneWare.Essentials" Version="0.4.2" Private="false" ExcludeAssets="runtime;Native"/>
<PackageReference Include="OneWare.UniversalFpgaProjectSystem" Version="0.16.3" Private="false" ExcludeAssets="runtime;Native"/>
</ItemGroup>

</Project>
19 changes: 5 additions & 14 deletions src/OneWare.Ghdl/Services/GhdlService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,10 @@ namespace OneWare.Ghdl.Services;
public class GhdlService
{
private readonly ILogger _logger;
private readonly IApplicationStateService _applicationStateService;
private readonly IDockService _dockService;
private readonly IProjectExplorerService _projectExplorerService;
private readonly INativeToolService _nativeToolService;
private readonly IChildProcessService _childProcessService;
private readonly IEnvironmentService _environmentService;

public AsyncRelayCommand SimulateCommand { get; }

Expand All @@ -38,16 +37,14 @@ public class GhdlService

private readonly NativeToolContainer _nativeToolContainer;

public GhdlService(ILogger logger, IApplicationStateService applicationStateService, IDockService dockService,
IProjectExplorerService projectExplorerService, ISettingsService settingsService,
INativeToolService nativeToolService, IChildProcessService childProcessService)
public GhdlService(ILogger logger, IDockService dockService, ISettingsService settingsService,
INativeToolService nativeToolService, IChildProcessService childProcessService, IEnvironmentService environmentService)
{
_logger = logger;
_applicationStateService = applicationStateService;
_dockService = dockService;
_projectExplorerService = projectExplorerService;
_nativeToolService = nativeToolService;
_childProcessService = childProcessService;
_environmentService = environmentService;
_nativeToolContainer = nativeToolService.Get("ghdl")!;

settingsService.GetSettingObservable<string>(GhdlModule.GhdlPathSetting).Subscribe(x =>
Expand Down Expand Up @@ -107,13 +104,7 @@ private void SetEnvironment()
{
if (File.Exists(_path))
{
var environmentPathSetting = PlatformHelper.Platform switch
{
PlatformId.WinX64 or PlatformId.WinArm64 => $";{Path.GetDirectoryName(_path)};",
_ => $":{Path.GetDirectoryName(_path)}:"
};
var currentPath = Environment.GetEnvironmentVariable("PATH");
Environment.SetEnvironmentVariable("PATH", $"{environmentPathSetting}{currentPath}");
_environmentService.SetPath("GHDL_PATH", Path.GetDirectoryName(_path));
}
}

Expand Down
4 changes: 2 additions & 2 deletions src/OneWare.Ghdl/oneware.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@
},
{
"Name": "OneWare.UniversalFpgaProjectSystem",
"MinVersion": "0.16.1.0",
"MaxVersion": "0.16.2.0"
"MinVersion": "0.16.3.0",
"MaxVersion": "0.16.3.0"
}
]
}

0 comments on commit e931be2

Please sign in to comment.