Merge pull request #1 from StevanFreeborn/stevanfreeborn/chore/update-build-to-fetch-resource-files
chore: fix workflows and build now that model files are not in the repository
This commit is contained in:
@@ -5,7 +5,6 @@ on:
|
|||||||
paths-ignore:
|
paths-ignore:
|
||||||
- "**/README.md"
|
- "**/README.md"
|
||||||
- "**/.gitignore"
|
- "**/.gitignore"
|
||||||
- "**/.gitaltributes"
|
|
||||||
- "**/.editorconfig"
|
- "**/.editorconfig"
|
||||||
- "**/LICENSE.md"
|
- "**/LICENSE.md"
|
||||||
- .github/**
|
- .github/**
|
||||||
@@ -19,7 +18,6 @@ jobs:
|
|||||||
- name: Checkout repository
|
- name: Checkout repository
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
lfs: true
|
|
||||||
fetch-depth: 0
|
fetch-depth: 0
|
||||||
token: ${{ secrets.ACTIONS_PAT }}
|
token: ${{ secrets.ACTIONS_PAT }}
|
||||||
- name: Setup .NET 9
|
- name: Setup .NET 9
|
||||||
@@ -59,7 +57,6 @@ jobs:
|
|||||||
- name: Checkout repository
|
- name: Checkout repository
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
lfs: true
|
|
||||||
fetch-depth: 0
|
fetch-depth: 0
|
||||||
ref: ${{ github.ref }}
|
ref: ${{ github.ref }}
|
||||||
token: ${{ secrets.ACTIONS_PAT }}
|
token: ${{ secrets.ACTIONS_PAT }}
|
||||||
|
|||||||
@@ -6,7 +6,6 @@ on:
|
|||||||
- "**/README.md"
|
- "**/README.md"
|
||||||
- "**/LICENSE.md"
|
- "**/LICENSE.md"
|
||||||
- "**/.gitignore"
|
- "**/.gitignore"
|
||||||
- "**/.gitattributes"
|
|
||||||
- "**/.editorconfig"
|
- "**/.editorconfig"
|
||||||
- .github/**
|
- .github/**
|
||||||
branches:
|
branches:
|
||||||
@@ -21,7 +20,6 @@ jobs:
|
|||||||
- name: Checkout repository
|
- name: Checkout repository
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
lfs: true
|
|
||||||
fetch-depth: 0
|
fetch-depth: 0
|
||||||
token: ${{ secrets.ACTIONS_PAT }}
|
token: ${{ secrets.ACTIONS_PAT }}
|
||||||
- name: Setup .NET
|
- name: Setup .NET
|
||||||
@@ -53,7 +51,6 @@ jobs:
|
|||||||
- name: Checkout repository
|
- name: Checkout repository
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
lfs: true
|
|
||||||
fetch-depth: 0
|
fetch-depth: 0
|
||||||
token: ${{ secrets.ACTIONS_PAT }}
|
token: ${{ secrets.ACTIONS_PAT }}
|
||||||
- name: Setup .NET 9
|
- name: Setup .NET 9
|
||||||
@@ -65,7 +62,7 @@ jobs:
|
|||||||
- name: Restore dependencies
|
- name: Restore dependencies
|
||||||
run: dotnet restore src
|
run: dotnet restore src
|
||||||
- name: Build on ${{ matrix.os }}
|
- name: Build on ${{ matrix.os }}
|
||||||
run: dotnet build src --no-restore
|
run: dotnet build --no-restore src
|
||||||
- name: Test on ${{ matrix.os }}
|
- name: Test on ${{ matrix.os }}
|
||||||
run: dotnet test src --no-build --verbosity normal
|
run: dotnet test src --no-build --verbosity normal
|
||||||
- name: Rename test coverage report
|
- name: Rename test coverage report
|
||||||
@@ -83,7 +80,6 @@ jobs:
|
|||||||
- name: Checkout repository
|
- name: Checkout repository
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
lfs: true
|
|
||||||
fetch-depth: 0
|
fetch-depth: 0
|
||||||
token: ${{ secrets.ACTIONS_PAT }}
|
token: ${{ secrets.ACTIONS_PAT }}
|
||||||
- name: Download ubuntu-latest report
|
- name: Download ubuntu-latest report
|
||||||
|
|||||||
@@ -12,6 +12,35 @@
|
|||||||
<OutputType>Exe</OutputType>
|
<OutputType>Exe</OutputType>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
|
<PropertyGroup>
|
||||||
|
<DownloadDirectory>Resources/Files</DownloadDirectory>
|
||||||
|
</PropertyGroup>
|
||||||
|
|
||||||
|
<Target Name="DownloadModels" BeforeTargets="PrepareForBuild">
|
||||||
|
<Message Text="Downloading models..." Importance="high" />
|
||||||
|
|
||||||
|
<MakeDir Directories="$(DownloadDirectory)" Condition="!Exists('$(DownloadDirectory)')" />
|
||||||
|
|
||||||
|
<Exec
|
||||||
|
Condition="!Exists('$(DownloadDirectory)/rmbg.onnx')"
|
||||||
|
Command="curl -L "https://share.stevanfreeborn.com/bgr/rmbg.onnx" -o "$(DownloadDirectory)/rmbg.onnx""
|
||||||
|
/>
|
||||||
|
|
||||||
|
<Exec
|
||||||
|
Condition="!Exists('$(DownloadDirectory)/u2net.onnx')"
|
||||||
|
Command="curl -L "https://share.stevanfreeborn.com/bgr/u2net.onnx" -o "$(DownloadDirectory)/u2net.onnx""
|
||||||
|
/>
|
||||||
|
|
||||||
|
<Exec
|
||||||
|
Condition="!Exists('$(DownloadDirectory)/modnet.onnx')"
|
||||||
|
Command="curl -L "https://share.stevanfreeborn.com/bgr/modnet.onnx" -o "$(DownloadDirectory)/modnet.onnx""
|
||||||
|
/>
|
||||||
|
|
||||||
|
<ItemGroup>
|
||||||
|
<EmbeddedResource Include="Resources\Files\**\*" />
|
||||||
|
</ItemGroup>
|
||||||
|
</Target>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<InternalsVisibleTo Include="$(AssemblyName).Tests" />
|
<InternalsVisibleTo Include="$(AssemblyName).Tests" />
|
||||||
<InternalsVisibleTo Include="DynamicProxyGenAssembly2" />
|
<InternalsVisibleTo Include="DynamicProxyGenAssembly2" />
|
||||||
@@ -31,8 +60,4 @@
|
|||||||
<PackageReference Include="Spectre.Console.Cli" Version="0.49.1" />
|
<PackageReference Include="Spectre.Console.Cli" Version="0.49.1" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
|
||||||
<EmbeddedResource Include="Resources\Files\**\*" />
|
|
||||||
</ItemGroup>
|
|
||||||
|
|
||||||
</Project>
|
</Project>
|
||||||
|
|||||||
Reference in New Issue
Block a user