Skip to content

Commit cba235a

Browse files
committed
Test the release workflow (a throwaway branch, not a release)
1 parent edc72f0 commit cba235a

54 files changed

Lines changed: 3575 additions & 1111 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎.github/workflows/release.yml‎

Lines changed: 88 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,88 @@
1+
# Written by DocSpring/docspring's api_clients/scripts/generate from api_clients/github_workflows/csharp/release.yml:
2+
# change it there.
3+
#
4+
# Packs the package on every push and pull request. A v* tag (pushed by the monorepo's api_clients/scripts/release)
5+
# also pushes it to NuGet with trusted publishing, in the release environment, and waits until NuGet serves it.
6+
name: Release
7+
8+
on:
9+
push:
10+
branches: ['**']
11+
tags: ['v*']
12+
pull_request:
13+
14+
permissions:
15+
contents: read
16+
17+
jobs:
18+
build:
19+
runs-on: ubuntu-latest
20+
steps:
21+
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
22+
with:
23+
persist-credentials: false
24+
- uses: actions/setup-dotnet@a98b56852c35b8e3190ac28c8c2271da59106c68 # v6.0.0
25+
with:
26+
dotnet-version: 9.0.x
27+
- name: Check the tag matches the package version
28+
if: github.ref_type == 'tag'
29+
run: |
30+
VERSION="$(sed -n 's:.*<Version>\(.*\)</Version>.*:\1:p' src/DocSpring.Client/DocSpring.Client.csproj)"
31+
if [ "v$VERSION" != "$GITHUB_REF_NAME" ]; then
32+
echo "::error::The tag is $GITHUB_REF_NAME, but the package version is $VERSION"
33+
exit 1
34+
fi
35+
- run: dotnet pack src/DocSpring.Client/DocSpring.Client.csproj --configuration Release --output out
36+
- if: github.ref_type == 'tag'
37+
uses: actions/upload-artifact@cf430e030ddbb5b0abf93d22962f4752f3646cd9 # v7.0.2
38+
with:
39+
name: package
40+
path: out/
41+
if-no-files-found: error
42+
43+
publish:
44+
needs: build
45+
if: github.ref_type == 'tag'
46+
runs-on: ubuntu-latest
47+
environment: release
48+
permissions:
49+
contents: read
50+
id-token: write
51+
steps:
52+
- uses: actions/setup-dotnet@a98b56852c35b8e3190ac28c8c2271da59106c68 # v6.0.0
53+
with:
54+
dotnet-version: 9.0.x
55+
- uses: actions/download-artifact@9000827ccba6bdab643e8b6fd33ac0654aef8333 # v8.0.2
56+
with:
57+
name: package
58+
path: out/
59+
# The nuget.org account that owns DocSpring.Client and its trusted publishing policy
60+
- uses: NuGet/login@8d196754b4036150537f80ac539e15c2f1028841 # v1.2.0
61+
id: login
62+
with:
63+
user: nathan-formapi
64+
- name: Push to NuGet
65+
env:
66+
NUGET_API_KEY: ${{ steps.login.outputs.NUGET_API_KEY }}
67+
run: |
68+
dotnet nuget push "out/DocSpring.Client.${GITHUB_REF_NAME#v}.nupkg" \
69+
--api-key "$NUGET_API_KEY" --source https://api.nuget.org/v3/index.json
70+
71+
verify:
72+
needs: publish
73+
runs-on: ubuntu-latest
74+
timeout-minutes: 30
75+
steps:
76+
# NuGet validates and indexes a package before it serves it, which can take a while
77+
- name: Wait until NuGet serves the version
78+
run: |
79+
VERSION="${GITHUB_REF_NAME#v}"
80+
for _ in $(seq 150); do
81+
if curl -fsS -o /dev/null "https://api.nuget.org/v3-flatcontainer/docspring.client/$VERSION/docspring.client.nuspec"; then
82+
echo "NuGet serves DocSpring.Client $VERSION"
83+
exit 0
84+
fi
85+
sleep 10
86+
done
87+
echo "::error::NuGet doesn't serve DocSpring.Client $VERSION after 25 minutes"
88+
exit 1

‎CHANGELOG.md‎

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,19 @@
1+
### 4.4.0 [October 31, 2026]
2+
3+
- New: page designs (`template_type` `page_designer`), PDFs designed in the Page Designer from a JSON layout, with no
4+
document to start from. create_template makes one from its `layout`, or with an empty page when `layout` is left
5+
out, and update_template replaces its layout. DocSpring adds a field for each value the layout reads. A template's
6+
`layout` is in the [Page Designer layout format](https://docspring.com/docs/page-designer/layout-format/) (its
7+
[JSON Schema](https://docspring.com/schemas/page-designer/layout.v1.json)), and is null for other templates.
8+
- New: every method that creates, changes or deletes something takes an `Idempotency-Key` header, as its last argument
9+
before `cancellationToken`, `idempotencyKey`. Send the same key when you send a request again after a timeout or a
10+
network error: within 24 hours, DocSpring returns the first response instead of running the request twice. Arguments
11+
you already pass keep their places.
12+
- Changed: the request validator checks what API v2 now refuses: an ID, a query value or a template name that's blank or
13+
only whitespace, an update with nothing to change, a version with a leading zero (`01`), a `filename` with a slash, a
14+
signer `email` that isn't an email address, and an HTML template's `scale` outside 0.1 to 2.
15+
- New: get_template_model_code takes `rust` as its `lang`, for Rust structs that serde reads and writes.
16+
117
### 4.3.0 [October 31, 2026]
218

319
- New: get_template_model_code takes `rust` as its `lang`, for Rust structs that serde reads and writes.

‎DocSpring.Client.sln‎

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ Microsoft Visual Studio Solution File, Format Version 12.00
22
# Visual Studio 14
33
VisualStudioVersion = 14.0.25420.1
44
MinimumVisualStudioVersion = 10.0.40219.1
5-
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DocSpring.Client", "src\DocSpring.Client\DocSpring.Client.csproj", "{9B41AA81-BE3B-4F5D-A774-E02801AD4385}"
5+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DocSpring.Client", "src\DocSpring.Client\DocSpring.Client.csproj", "{C29C6D10-A577-4C78-9734-FE65CB32F366}"
66
EndProject
77
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DocSpring.Client.Test", "src\DocSpring.Client.Test\DocSpring.Client.Test.csproj", "{19F1DEBC-DE5E-4517-8062-F000CD499087}"
88
EndProject
@@ -12,10 +12,10 @@ Global
1212
Release|Any CPU = Release|Any CPU
1313
EndGlobalSection
1414
GlobalSection(ProjectConfigurationPlatforms) = postSolution
15-
{9B41AA81-BE3B-4F5D-A774-E02801AD4385}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
16-
{9B41AA81-BE3B-4F5D-A774-E02801AD4385}.Debug|Any CPU.Build.0 = Debug|Any CPU
17-
{9B41AA81-BE3B-4F5D-A774-E02801AD4385}.Release|Any CPU.ActiveCfg = Release|Any CPU
18-
{9B41AA81-BE3B-4F5D-A774-E02801AD4385}.Release|Any CPU.Build.0 = Release|Any CPU
15+
{C29C6D10-A577-4C78-9734-FE65CB32F366}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
16+
{C29C6D10-A577-4C78-9734-FE65CB32F366}.Debug|Any CPU.Build.0 = Debug|Any CPU
17+
{C29C6D10-A577-4C78-9734-FE65CB32F366}.Release|Any CPU.ActiveCfg = Release|Any CPU
18+
{C29C6D10-A577-4C78-9734-FE65CB32F366}.Release|Any CPU.Build.0 = Release|Any CPU
1919
{19F1DEBC-DE5E-4517-8062-F000CD499087}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
2020
{19F1DEBC-DE5E-4517-8062-F000CD499087}.Debug|Any CPU.Build.0 = Debug|Any CPU
2121
{19F1DEBC-DE5E-4517-8062-F000CD499087}.Release|Any CPU.ActiveCfg = Release|Any CPU

‎README.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ e-signatures.
1010
The code in this repository is generated from DocSpring's OpenAPI spec ([About this SDK](#about-this-sdk)). Issues and
1111
pull requests are welcome.
1212

13-
Version 4.3.0. Requires .NET Standard 2.0 (.NET 6 or later, or .NET Framework 4.6.2 or later).
13+
Version 4.4.0. Requires .NET Standard 2.0 (.NET 6 or later, or .NET Framework 4.6.2 or later).
1414

1515
## Install and configure
1616

0 commit comments

Comments
 (0)