Skip to content

Commit 9102720

Browse files
authored
better release script (and overall updates) (#102)
1 parent abd3baa commit 9102720

File tree

14 files changed

+773
-1215
lines changed

14 files changed

+773
-1215
lines changed

.config/dotnet-tools.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,13 @@
33
"isRoot": true,
44
"tools": {
55
"fake-cli": {
6-
"version": "5.20.3",
6+
"version": "5.21.0-alpha004",
77
"commands": [
88
"fake"
99
]
1010
},
1111
"paket": {
12-
"version": "5.257.0",
12+
"version": "6.2.1",
1313
"commands": [
1414
"paket"
1515
]

.github/workflows/main.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ jobs:
88
strategy:
99
matrix:
1010
os: [ubuntu-latest, windows-latest, macOS-latest]
11-
dotnet: [5.0.102]
11+
dotnet: [6.0.100]
1212
runs-on: ${{ matrix.os }}
1313

1414
steps:
@@ -23,3 +23,7 @@ jobs:
2323
run: dotnet paket restore
2424
- name: Build
2525
run: dotnet fake run build.fsx
26+
- name: Upload a Build Artifact
27+
uses: actions/[email protected]
28+
with:
29+
path: out

.github/workflows/release.yml

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
name: Release
2+
3+
on:
4+
push:
5+
tags:
6+
- 'v*'
7+
8+
jobs:
9+
release:
10+
strategy:
11+
matrix:
12+
dotnet: [6.0.100]
13+
14+
runs-on: ubuntu-20.04
15+
16+
steps:
17+
- uses: actions/checkout@v2
18+
with:
19+
ref: ${{ github.head_ref }}
20+
- name: Setup .NET Core
21+
uses: actions/setup-dotnet@v1
22+
with:
23+
dotnet-version: ${{ matrix.dotnet }}
24+
- name: Restore tools
25+
run: dotnet tool restore
26+
- name: Restore
27+
run: dotnet restore
28+
- name: build and push packages
29+
run: dotnet fake build -t Push
30+
env:
31+
nuget-key: ${{ secrets.NUGET_KEY }}
32+
- name: Upload a Build Artifact
33+
uses: actions/[email protected]
34+
with:
35+
path: out
36+
- name: Create Release
37+
uses: ncipollo/release-action@v1
38+
with:
39+
artifacts: out/*.nupkg
40+
token: ${{ secrets.GITHUB_TOKEN }}
41+
generateReleaseNotes: true

.paket/Paket.Restore.targets

Lines changed: 71 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,7 @@
159159
This value should match the version in the props generated by paket
160160
If they differ, this means we need to do a restore in order to ensure correct dependencies
161161
-->
162-
<PropertyGroup Condition="'$(PaketPropsVersion)' != '5.185.3' ">
162+
<PropertyGroup Condition="'$(PaketPropsVersion)' != '6.0.0' ">
163163
<PaketRestoreRequired>true</PaketRestoreRequired>
164164
</PropertyGroup>
165165

@@ -236,13 +236,16 @@
236236
<PackageName>$([System.String]::Copy('%(PaketReferencesFileLines.Identity)').Split(',')[0])</PackageName>
237237
<PackageVersion>$([System.String]::Copy('%(PaketReferencesFileLines.Identity)').Split(',')[1])</PackageVersion>
238238
<AllPrivateAssets>$([System.String]::Copy('%(PaketReferencesFileLines.Identity)').Split(',')[4])</AllPrivateAssets>
239-
<CopyLocal Condition="'%(PaketReferencesFileLinesInfo.Splits)' == '6'">$([System.String]::Copy('%(PaketReferencesFileLines.Identity)').Split(',')[5])</CopyLocal>
239+
<CopyLocal Condition="%(PaketReferencesFileLinesInfo.Splits) &gt;= 6">$([System.String]::Copy('%(PaketReferencesFileLines.Identity)').Split(',')[5])</CopyLocal>
240+
<OmitContent Condition="%(PaketReferencesFileLinesInfo.Splits) &gt;= 7">$([System.String]::Copy('%(PaketReferencesFileLines.Identity)').Split(',')[6])</OmitContent>
241+
<ImportTargets Condition="%(PaketReferencesFileLinesInfo.Splits) &gt;= 8">$([System.String]::Copy('%(PaketReferencesFileLines.Identity)').Split(',')[7])</ImportTargets>
240242
</PaketReferencesFileLinesInfo>
241243
<PackageReference Include="%(PaketReferencesFileLinesInfo.PackageName)">
242244
<Version>%(PaketReferencesFileLinesInfo.PackageVersion)</Version>
243245
<PrivateAssets Condition=" ('%(PaketReferencesFileLinesInfo.AllPrivateAssets)' == 'true') Or ('$(PackAsTool)' == 'true') ">All</PrivateAssets>
244-
<ExcludeAssets Condition=" '%(PaketReferencesFileLinesInfo.Splits)' == '6' And %(PaketReferencesFileLinesInfo.CopyLocal) == 'false'">runtime</ExcludeAssets>
245-
<ExcludeAssets Condition=" '%(PaketReferencesFileLinesInfo.Splits)' != '6' And %(PaketReferencesFileLinesInfo.AllPrivateAssets) == 'exclude'">runtime</ExcludeAssets>
246+
<ExcludeAssets Condition=" %(PaketReferencesFileLinesInfo.CopyLocal) == 'false' or %(PaketReferencesFileLinesInfo.AllPrivateAssets) == 'exclude'">runtime</ExcludeAssets>
247+
<ExcludeAssets Condition=" %(PaketReferencesFileLinesInfo.OmitContent) == 'true'">$(ExcludeAssets);contentFiles</ExcludeAssets>
248+
<ExcludeAssets Condition=" %(PaketReferencesFileLinesInfo.ImportTargets) == 'false'">$(ExcludeAssets);build;buildMultitargeting;buildTransitive</ExcludeAssets>
246249
<Publish Condition=" '$(PackAsTool)' == 'true' ">true</Publish>
247250
<AllowExplicitVersion>true</AllowExplicitVersion>
248251
</PackageReference>
@@ -289,14 +292,16 @@
289292
<PropertyGroup>
290293
<PaketProjectFile>$(MSBuildProjectDirectory)/$(MSBuildProjectFile)</PaketProjectFile>
291294
<ContinuePackingAfterGeneratingNuspec>true</ContinuePackingAfterGeneratingNuspec>
295+
<UseMSBuild16_10_Pack>false</UseMSBuild16_10_Pack>
296+
<UseMSBuild16_10_Pack Condition=" '@(MSBuildMajorVersion)' >= '16' AND '@(MSBuildMinorVersion)' > '10' ">true</UseMSBuild16_10_Pack>
292297
<UseMSBuild16_0_Pack>false</UseMSBuild16_0_Pack>
293-
<UseMSBuild16_0_Pack Condition=" '@(MSBuildMajorVersion)' >= '16' ">true</UseMSBuild16_0_Pack>
298+
<UseMSBuild16_0_Pack Condition=" '@(MSBuildMajorVersion)' >= '16' AND (! $(UseMSBuild16_10_Pack)) ">true</UseMSBuild16_0_Pack>
294299
<UseMSBuild15_9_Pack>false</UseMSBuild15_9_Pack>
295300
<UseMSBuild15_9_Pack Condition=" '@(MSBuildMajorVersion)' == '15' AND '@(MSBuildMinorVersion)' > '8' ">true</UseMSBuild15_9_Pack>
296301
<UseMSBuild15_8_Pack>false</UseMSBuild15_8_Pack>
297-
<UseMSBuild15_8_Pack Condition=" '$(NuGetToolVersion)' != '4.0.0' AND (! $(UseMSBuild15_9_Pack)) AND (! $(UseMSBuild16_0_Pack)) ">true</UseMSBuild15_8_Pack>
302+
<UseMSBuild15_8_Pack Condition=" '$(NuGetToolVersion)' != '4.0.0' AND (! $(UseMSBuild15_9_Pack)) AND (! $(UseMSBuild16_0_Pack)) AND (! $(UseMSBuild16_10_Pack)) ">true</UseMSBuild15_8_Pack>
298303
<UseNuGet4_Pack>false</UseNuGet4_Pack>
299-
<UseNuGet4_Pack Condition=" (! $(UseMSBuild15_8_Pack)) AND (! $(UseMSBuild15_9_Pack)) AND (! $(UseMSBuild16_0_Pack)) ">true</UseNuGet4_Pack>
304+
<UseNuGet4_Pack Condition=" (! $(UseMSBuild15_8_Pack)) AND (! $(UseMSBuild15_9_Pack)) AND (! $(UseMSBuild16_0_Pack)) AND (! $(UseMSBuild16_10_Pack)) ">true</UseNuGet4_Pack>
300305
<AdjustedNuspecOutputPath>$(PaketIntermediateOutputPath)\$(Configuration)</AdjustedNuspecOutputPath>
301306
<AdjustedNuspecOutputPath Condition="@(_NuspecFilesNewLocation) == ''">$(PaketIntermediateOutputPath)</AdjustedNuspecOutputPath>
302307
</PropertyGroup>
@@ -314,6 +319,55 @@
314319
</ConvertToAbsolutePath>
315320

316321
<!-- Call Pack -->
322+
<PackTask Condition="$(UseMSBuild16_10_Pack)"
323+
PackItem="$(PackProjectInputFile)"
324+
PackageFiles="@(_PackageFiles)"
325+
PackageFilesToExclude="@(_PackageFilesToExclude)"
326+
PackageVersion="$(PackageVersion)"
327+
PackageId="$(PackageId)"
328+
Title="$(Title)"
329+
Authors="$(Authors)"
330+
Description="$(Description)"
331+
Copyright="$(Copyright)"
332+
RequireLicenseAcceptance="$(PackageRequireLicenseAcceptance)"
333+
LicenseUrl="$(PackageLicenseUrl)"
334+
ProjectUrl="$(PackageProjectUrl)"
335+
IconUrl="$(PackageIconUrl)"
336+
ReleaseNotes="$(PackageReleaseNotes)"
337+
Tags="$(PackageTags)"
338+
DevelopmentDependency="$(DevelopmentDependency)"
339+
BuildOutputInPackage="@(_BuildOutputInPackage)"
340+
TargetPathsToSymbols="@(_TargetPathsToSymbols)"
341+
SymbolPackageFormat="$(SymbolPackageFormat)"
342+
TargetFrameworks="@(_TargetFrameworks)"
343+
AssemblyName="$(AssemblyName)"
344+
PackageOutputPath="$(PackageOutputAbsolutePath)"
345+
IncludeSymbols="$(IncludeSymbols)"
346+
IncludeSource="$(IncludeSource)"
347+
PackageTypes="$(PackageType)"
348+
IsTool="$(IsTool)"
349+
RepositoryUrl="$(RepositoryUrl)"
350+
RepositoryType="$(RepositoryType)"
351+
SourceFiles="@(_SourceFiles->Distinct())"
352+
NoPackageAnalysis="$(NoPackageAnalysis)"
353+
MinClientVersion="$(MinClientVersion)"
354+
Serviceable="$(Serviceable)"
355+
FrameworkAssemblyReferences="@(_FrameworkAssemblyReferences)"
356+
ContinuePackingAfterGeneratingNuspec="$(ContinuePackingAfterGeneratingNuspec)"
357+
NuspecOutputPath="$(AdjustedNuspecOutputPath)"
358+
IncludeBuildOutput="$(IncludeBuildOutput)"
359+
BuildOutputFolders="$(BuildOutputTargetFolder)"
360+
ContentTargetFolders="$(ContentTargetFolders)"
361+
RestoreOutputPath="$(RestoreOutputAbsolutePath)"
362+
NuspecFile="$(NuspecFileAbsolutePath)"
363+
NuspecBasePath="$(NuspecBasePath)"
364+
NuspecProperties="$(NuspecProperties)"
365+
PackageLicenseFile="$(PackageLicenseFile)"
366+
PackageLicenseExpression="$(PackageLicenseExpression)"
367+
PackageLicenseExpressionVersion="$(PackageLicenseExpressionVersion)"
368+
Readme="$(PackageReadmeFile)"
369+
NoDefaultExcludes="$(NoDefaultExcludes)"/>
370+
317371
<PackTask Condition="$(UseMSBuild16_0_Pack)"
318372
PackItem="$(PackProjectInputFile)"
319373
PackageFiles="@(_PackageFiles)"
@@ -343,6 +397,8 @@
343397
IsTool="$(IsTool)"
344398
RepositoryUrl="$(RepositoryUrl)"
345399
RepositoryType="$(RepositoryType)"
400+
RepositoryBranch="$(RepositoryBranch)"
401+
RepositoryCommit="$(RepositoryCommit)"
346402
SourceFiles="@(_SourceFiles->Distinct())"
347403
NoPackageAnalysis="$(NoPackageAnalysis)"
348404
MinClientVersion="$(MinClientVersion)"
@@ -359,7 +415,8 @@
359415
NuspecProperties="$(NuspecProperties)"
360416
PackageLicenseFile="$(PackageLicenseFile)"
361417
PackageLicenseExpression="$(PackageLicenseExpression)"
362-
PackageLicenseExpressionVersion="$(PackageLicenseExpressionVersion)" />
418+
PackageLicenseExpressionVersion="$(PackageLicenseExpressionVersion)"
419+
NoDefaultExcludes="$(NoDefaultExcludes)" />
363420

364421
<PackTask Condition="$(UseMSBuild15_9_Pack)"
365422
PackItem="$(PackProjectInputFile)"
@@ -390,6 +447,8 @@
390447
IsTool="$(IsTool)"
391448
RepositoryUrl="$(RepositoryUrl)"
392449
RepositoryType="$(RepositoryType)"
450+
RepositoryBranch="$(RepositoryBranch)"
451+
RepositoryCommit="$(RepositoryCommit)"
393452
SourceFiles="@(_SourceFiles->Distinct())"
394453
NoPackageAnalysis="$(NoPackageAnalysis)"
395454
MinClientVersion="$(MinClientVersion)"
@@ -433,6 +492,8 @@
433492
IsTool="$(IsTool)"
434493
RepositoryUrl="$(RepositoryUrl)"
435494
RepositoryType="$(RepositoryType)"
495+
RepositoryBranch="$(RepositoryBranch)"
496+
RepositoryCommit="$(RepositoryCommit)"
436497
SourceFiles="@(_SourceFiles->Distinct())"
437498
NoPackageAnalysis="$(NoPackageAnalysis)"
438499
MinClientVersion="$(MinClientVersion)"
@@ -475,6 +536,8 @@
475536
IsTool="$(IsTool)"
476537
RepositoryUrl="$(RepositoryUrl)"
477538
RepositoryType="$(RepositoryType)"
539+
RepositoryBranch="$(RepositoryBranch)"
540+
RepositoryCommit="$(RepositoryCommit)"
478541
SourceFiles="@(_SourceFiles->Distinct())"
479542
NoPackageAnalysis="$(NoPackageAnalysis)"
480543
MinClientVersion="$(MinClientVersion)"

CHANGELOG.md

Lines changed: 44 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,37 +1,73 @@
1-
### 0.13.1 - 24.04.2020
1+
# Changelog
2+
3+
## 0.14.0 - 15.01.2022
4+
5+
### Added
6+
7+
* Update to FCS 41
8+
* Add Sourcelink to the core library
9+
* Support .NET 5 and .NET 6
10+
* typo fix for the About page
11+
* Trim file paths with a platform-agnostic path separator (#91)
12+
* Add some Generator documentation.
13+
* Minor readme grammatical fixes (#83)
14+
* Misc fixes (#80)
15+
* Watch mode enhancement (#79)
16+
* Update to .NET 5 (#78)
17+
* Change after testing on Windows Directory.Delete throws exception on files with read-only attribute.
18+
* Add LibGit2Sharp, add sub commands to fornax new
19+
* Update FCS, fake-cli and paket. (#73)
20+
* Add GitHub Actions build (#74)
21+
* Improve mobile layout
22+
* allow the user to configure pages size in the global loader
23+
* Add support for paging
24+
* Improve perf by caching generators (#65)
25+
* Default template does not support on sub-dirs (#64)
26+
* fix typo (#62)
27+
28+
## 0.13.1 - 24.04.2020
29+
30+
### Added
231
* Update to FCS 35.0 (by [@Krzysztof-Cieslak](https://github.com/Krzysztof-Cieslak))
332
* Pass `WATCH` define in case of watch mode (by [@Krzysztof-Cieslak](https://github.com/Krzysztof-Cieslak))
433

5-
### 0.13.0 - 20.04.2020
34+
## 0.13.0 - 20.04.2020
35+
### Added
636
* Add way to check developments to the template (by [@robertpi](https://github.com/robertpi))
737
* Summarize posts using more marker (by [@robertpi](https://github.com/robertpi))
838
* Update to FCS 34.1 (by [@Krzysztof-Cieslak](https://github.com/Krzysztof-Cieslak))
939

10-
### 0.12.0 - 14.04.2020
40+
## 0.12.0 - 14.04.2020
41+
### Added
1142
* WebSocket refresh uses excesive CPU (by [@robertpi](https://github.com/robertpi))
1243
* Allow generate to return a byte array (by [@robertpi](https://github.com/robertpi))
1344
* Refactor template (by [@robertpi](https://github.com/robertpi))
1445

15-
### 0.11.1 - 07.04.2020
46+
## 0.11.1 - 07.04.2020
47+
### Added
1648
* Fix for once generator running even if not found (by [@sasmithjr](https://github.com/sasmithjr))
1749
* Use exceptions .ToString() when printing error (by [@robertpi](https://github.com/robertpi))
1850

19-
### 0.11.0 - 02.03.2020
51+
## 0.11.0 - 02.03.2020
52+
### Added
2053
* Add a port argument to the watch command (by [@toburger](https://github.com/toburger))
2154
* Collect and propogate loader errors (by [@jbeeko](https://github.com/jbeeko))
2255
* Add MultipleFiles as possible generator output (by [@Krzysztof-Cieslak](https://github.com/Krzysztof-Cieslak))
2356

24-
### 0.10.0 - 20.02.2020
57+
## 0.10.0 - 20.02.2020
58+
### Added
2559
* Update to .NET Core 3.0
2660
* Adds tools manifest .config/dotnet-tools.json
2761
* Redesign Fornax around idea of `loaders` and `generators`
2862
* Create new `fornax new` template
2963

30-
### 0.2.0 - 05.08.2019
64+
## 0.2.0 - 05.08.2019
65+
### Added
3166
* Update to .Net Core
3267
* Distribute as .Net Core global tool
3368

34-
### 0.1.0 - 04.06.2017
69+
## 0.1.0 - 04.06.2017
70+
### Added
3571
* Defining templates in F# DSL
3672
* Creating pages using templates from `.md` files with `layout` entry
3773
* Creating plain pages without templates from `md` files without `layout` entry

Directory.Build.props

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
<Project>
2+
<PropertyGroup>
3+
<Product>Fornax</Product>
4+
<Description>Fornax is a static site generator using type safe F# DSL to define page layouts.</Description>
5+
<Authors>Krzysztof Cieslak</Authors>
6+
<PackageTags>f#, site-generator, html</PackageTags>
7+
<PackageProjectUrl>https://github.com/Ionide/Fornax</PackageProjectUrl>
8+
<PackageLicenseExpression>MIT</PackageLicenseExpression>
9+
<ChangelogFile>$(MSBuildThisFileDirectory)CHANGELOG.md</ChangelogFile>
10+
<PackageReadmeFile>README.md</PackageReadmeFile>
11+
</PropertyGroup>
12+
<ItemGroup Condition="'$(IsPackable)' =='true'">
13+
<None Include="$(MSBuildThisFileDirectory)/README.md" Pack="true" PackagePath="/" />
14+
</ItemGroup>
15+
</Project>

0 commit comments

Comments
 (0)