Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ jobs:

strategy:
matrix:
os: ['ubuntu-24.04', 'windows-2022']
os: ['ubuntu-24.04', 'windows-2025']

env:
Configuration: 'Release'
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ env:

jobs:
release:
runs-on: ubuntu-22.04
runs-on: ubuntu-24.04

steps:
- name: checkout
Expand All @@ -28,7 +28,7 @@ jobs:
- name: setup dotnet
uses: actions/setup-dotnet@v5
with:
dotnet-version: 8
dotnet-version: 10

- name: restore
run: dotnet restore
Expand Down
4 changes: 2 additions & 2 deletions src/Directory.Build.props
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
<Project>

<PropertyGroup>
<TargetFrameworks>net6.0;net7.0;net8.0</TargetFrameworks>
<TargetFrameworks>net8.0;net10.0</TargetFrameworks>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
<VersionPrefix>1.8.0</VersionPrefix>
<VersionPrefix>2.0.0</VersionPrefix>
</PropertyGroup>

<PropertyGroup>
Expand Down
2 changes: 1 addition & 1 deletion src/VbaCompiler/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ var macroFilePath = compiler.CompileExcelMacroFile("bin", "MyMacro.xlsm", vbaPro

### Requirements

The compiler works on .NET 6, 7 and 8 runtimes on Windows and macOS.
The compiler works on .NET 8 and 10 runtimes on Windows, Linux and macOS.

### Samples

Expand Down
10 changes: 5 additions & 5 deletions src/VbaCompiler/Vba/ProjectRecord.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,11 @@ public class ProjectRecord
{
public ProjectRecord()
{
this.HostExtenders = new List<string>()
{
this.HostExtenders =
[
Constants.HostExtender_VBE
};
this.Modules = new List<ModuleUnit>();
];
this.Modules = [];
}

public string Id { get; set; } = "";
Expand All @@ -37,7 +37,7 @@ public ProjectRecord()
/// </summary>
public string VisibilityState { get; set; } = "";

public IList<string> HostExtenders { get; }
public List<string> HostExtenders { get; }

public ICollection<ModuleUnit> Modules { get; set; }

Expand Down
4 changes: 2 additions & 2 deletions src/VbaCompiler/VbaCompiler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@ namespace vbamc
{
public class VbaCompiler
{
private IList<ModuleUnit> modules = new List<ModuleUnit>();
private List<ModuleUnit> modules = [];

public IDictionary<string, string> ExtendedProperties { get; set; } = new Dictionary<string, string>();
public Dictionary<string, string> ExtendedProperties { get; set; } = [];

public Guid ProjectId { get; set; }

Expand Down
7 changes: 3 additions & 4 deletions src/VbaCompiler/VbaCompiler.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,9 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="DocumentFormat.OpenXml" Version="3.0.2" />
<PackageReference Include="OpenMcdf" Version="2.3.1" />
<PackageReference Include="NetOfficeFw.VbaCompression" Version="2.0.0" />
<PackageReference Include="System.Collections.Specialized" Version="4.3.0" />
<PackageReference Include="DocumentFormat.OpenXml" Version="3.3.0" />
<PackageReference Include="OpenMcdf" Version="2.4.1" />
<PackageReference Include="NetOfficeFw.VbaCompression" Version="3.0.1" />
</ItemGroup>

<ItemGroup>
Expand Down
6 changes: 3 additions & 3 deletions src/vbamc/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@ public static int Main(string[] args)

[Required]
[Option("-m|--module")]
public IEnumerable<string> Modules { get; } = Enumerable.Empty<string>();
public IEnumerable<string> Modules { get; } = [];

[Option("-c|--class")]
public IEnumerable<string> Classes { get; } = Enumerable.Empty<string>();
public IEnumerable<string> Classes { get; } = [];

// [Option("-d|--document")]
// public string? Document { get; }
Expand All @@ -39,7 +39,7 @@ public static int Main(string[] args)
public string? UserProfilePath { get; }

[Option("-p|--property", Description = "Extended property in the format name=value")]
public string[] ExtendedProperties { get; } = Array.Empty<string>();
public string[] ExtendedProperties { get; } = [];

private void OnExecute()
{
Expand Down
2 changes: 1 addition & 1 deletion src/vbamc/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ vbamc --module Module.vb --class MyClass.vb --name "VBA Project" --company "ACME

### Requirements

The compiler works on .NET 6, 7 and 8 runtimes on Windows and macOS.
The compiler works on .NET 8 and 10 runtimes on Windows, Linux and macOS.

### Samples

Expand Down
13 changes: 5 additions & 8 deletions tests/VbaCompiler.Tests/VbaCompiler.Tests.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<TargetFrameworks>net8.0;net10.0</TargetFrameworks>
<Nullable>enable</Nullable>

<IsPackable>false</IsPackable>
Expand All @@ -22,16 +22,13 @@
</ItemGroup>

<ItemGroup>
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.9.0" />
<PackageReference Include="NUnit" Version="4.1.0" />
<PackageReference Include="NUnit3TestAdapter" Version="4.5.0" />
<PackageReference Include="coverlet.collector" Version="6.0.2">
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="18.0.0" />
<PackageReference Include="NUnit" Version="4.4.0" />
<PackageReference Include="NUnit3TestAdapter" Version="5.2.0" />
<PackageReference Include="coverlet.collector" Version="6.0.4">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="System.Collections" Version="4.3.0" />
<PackageReference Include="System.IO.FileSystem.Primitives" Version="4.3.0" />
<PackageReference Include="System.Text.Encoding.Extensions" Version="4.3.0" />
</ItemGroup>

<ItemGroup>
Expand Down
6 changes: 3 additions & 3 deletions utils/vbad/vbad.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@

<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net8.0</TargetFramework>
<TargetFramework>net10.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="OpenMcdf" Version="2.3.1" />
<PackageReference Include="NetOfficeFw.VbaCompression" Version="2.0.0" />
<PackageReference Include="OpenMcdf" Version="2.4.1" />
<PackageReference Include="NetOfficeFw.VbaCompression" Version="3.0.1" />
</ItemGroup>

</Project>
58 changes: 0 additions & 58 deletions vbamc.sln

This file was deleted.

13 changes: 13 additions & 0 deletions vbamc.slnx
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<Solution>
<Project Path="src/VbaCompiler/VbaCompiler.csproj" />
<Project Path="src/vbamc/vbamc.csproj" />

<Folder Name="/utils/">
<Project Path="utils/vbad/vbad.csproj" />
</Folder>

<Folder Name="/tests/">
<Project Path="tests/VbaCompiler.Benchmark/VbaCompiler.Benchmark.csproj" />
<Project Path="tests/VbaCompiler.Tests/VbaCompiler.Tests.csproj" />
</Folder>
</Solution>