Skip to content

Commit

Permalink
Simplified pack-script, updated workflow, added solution
Browse files Browse the repository at this point in the history
  • Loading branch information
tidyui committed May 29, 2020
1 parent 597a5f8 commit 1589fe2
Show file tree
Hide file tree
Showing 3 changed files with 42 additions and 19 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/publish_to_nuget.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
- name: Setup .NET Core @ Latest
uses: actions/setup-dotnet@v1
with:
source-url: https://nuget.pkg.github.com/tidyui/index.json
source-url: https://api.nuget.org/v3/index.json
env:
NUGET_AUTH_TOKEN: ${{secrets.NugetAuthToken}}

Expand All @@ -26,4 +26,4 @@ jobs:

# Push to NuGet
- name: Push generated package to GitHub registry
run: dotnet nuget push **/*.nupkg --skip-duplicate
run: dotnet nuget push **/*.nupkg --skip-duplicate -k ${{ secrets.NugetAuthToken }}
39 changes: 39 additions & 0 deletions Statica.sln
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 15
VisualStudioVersion = 15.0.26124.0
MinimumVisualStudioVersion = 15.0.26124.0
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "src", "src", "{18B1C0CD-8365-43BB-9D64-8F740181FEA0}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Statica", "src\Statica\Statica.csproj", "{86D1C2BF-BA6E-4355-9538-3A77BD15A7BF}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Debug|x64 = Debug|x64
Debug|x86 = Debug|x86
Release|Any CPU = Release|Any CPU
Release|x64 = Release|x64
Release|x86 = Release|x86
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{86D1C2BF-BA6E-4355-9538-3A77BD15A7BF}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{86D1C2BF-BA6E-4355-9538-3A77BD15A7BF}.Debug|Any CPU.Build.0 = Debug|Any CPU
{86D1C2BF-BA6E-4355-9538-3A77BD15A7BF}.Debug|x64.ActiveCfg = Debug|Any CPU
{86D1C2BF-BA6E-4355-9538-3A77BD15A7BF}.Debug|x64.Build.0 = Debug|Any CPU
{86D1C2BF-BA6E-4355-9538-3A77BD15A7BF}.Debug|x86.ActiveCfg = Debug|Any CPU
{86D1C2BF-BA6E-4355-9538-3A77BD15A7BF}.Debug|x86.Build.0 = Debug|Any CPU
{86D1C2BF-BA6E-4355-9538-3A77BD15A7BF}.Release|Any CPU.ActiveCfg = Release|Any CPU
{86D1C2BF-BA6E-4355-9538-3A77BD15A7BF}.Release|Any CPU.Build.0 = Release|Any CPU
{86D1C2BF-BA6E-4355-9538-3A77BD15A7BF}.Release|x64.ActiveCfg = Release|Any CPU
{86D1C2BF-BA6E-4355-9538-3A77BD15A7BF}.Release|x64.Build.0 = Release|Any CPU
{86D1C2BF-BA6E-4355-9538-3A77BD15A7BF}.Release|x86.ActiveCfg = Release|Any CPU
{86D1C2BF-BA6E-4355-9538-3A77BD15A7BF}.Release|x86.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(NestedProjects) = preSolution
{86D1C2BF-BA6E-4355-9538-3A77BD15A7BF} = {18B1C0CD-8365-43BB-9D64-8F740181FEA0}
EndGlobalSection
EndGlobal
18 changes: 1 addition & 17 deletions pack.sh
Original file line number Diff line number Diff line change
@@ -1,21 +1,5 @@
#!/usr/bin/env bash

# Define directories
SCRIPT_DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
OUTPUT_DIR=$SCRIPT_DIR/artifacts

# Clean and build in release
cd src/Statica
dotnet restore
dotnet clean
dotnet build -c Release
cd ..
cd ..

# Make sure output folder exist.
if [ ! -d "$OUTPUT_DIR" ]; then
mkdir "$OUTPUT_DIR"
fi

# Create all NuGet packages
dotnet pack src/Statica/Statica.csproj --no-build -c Release -o $OUTPUT_DIR
dotnet pack --no-build -c Release -o ./artifacts

0 comments on commit 1589fe2

Please sign in to comment.