<?xml version="1.0" encoding="utf-16"?>
<rss xmlns:a10="http://www.w3.org/2005/Atom" version="2.0">
  <channel>
    <title>patriksvensson.se</title>
    <link>https://patriksvensson.se/</link>
    <description>Patrik Svensson's blog</description>
    <language>en-us</language>
    <lastBuildDate>Tue, 10 Mar 2026 23:35:23 Z</lastBuildDate>
    <item>
      <guid isPermaLink="false">/blog/2018/01/calculating-msi-product-version</guid>
      <link>https://patriksvensson.se/blog/2018/01/calculating-msi-product-version</link>
      <title>Calculating product versions for MSI packages compatible with semantic versioning</title>
      <description>In my new project Jarvis I wanted to start generate preview versions of the MSI packages, but one problem with that is that MSI requires the product version to be in the format Major.Minor.Patch which isn't compatible with semantic verisoning. We CAN use the Major.Minor.Patch.Revision format as a product version, but that won't work with major upgrades. An example of this would be 1.2.3-alpha45 which would require a different version number than 1.2.3-alpha46.</description>
      <a10:updated>2018-01-30T00:00:00Z</a10:updated>
    </item>
    <item>
      <guid isPermaLink="false">/blog/2018/10/generating-api-clients-using-autorest</guid>
      <link>https://patriksvensson.se/blog/2018/10/generating-api-clients-using-autorest</link>
      <title>Generating API clients using AutoRest</title>
      <description>This blog post looks at automatically generating an HTTP API client from a OpenAPI specification (formerly swagger) using AutoRest.</description>
      <a10:updated>2018-10-02T00:00:00Z</a10:updated>
    </item>
    <item>
      <guid isPermaLink="false">/blog/2020/02/testing-stuff-with-windows-sandbox</guid>
      <link>https://patriksvensson.se/blog/2020/02/testing-stuff-with-windows-sandbox</link>
      <title>Testing stuff with Windows Sandbox</title>
      <description>Last week I decided that I wanted to try the new version of Windows Subsystem for Linux (conveniently named WSL 2). WSL 2 requires that the computer enrolls in Windows slow ring, and since the computer I was on didn't receive any insider builds at all, I went ahead and enabled the slow ring. The update started, and I went to bed.</description>
      <a10:updated>2020-02-23T00:00:00Z</a10:updated>
    </item>
    <item>
      <guid isPermaLink="false">/blog/2020/10/thank-you-octopus-deploy</guid>
      <link>https://patriksvensson.se/blog/2020/10/thank-you-octopus-deploy</link>
      <title>Thank you Octopus Deploy!</title>
      <description>When I started working on Cake in 2014, I did it to scratch an itch I had. FAKE existed (which has been a tremendous initial inspiration), but I didn't know F# enough (at all) to be confident enough to bet our build process on it.</description>
      <a10:updated>2020-10-08T00:00:00Z</a10:updated>
    </item>
    <item>
      <guid isPermaLink="false">/blog/2020/06/deploying-to-nuget-from-github-actions-using-cake-and-minver</guid>
      <link>https://patriksvensson.se/blog/2020/06/deploying-to-nuget-from-github-actions-using-cake-and-minver</link>
      <title>Deploying to NuGet from GitHub Actions using Cake and MinVer</title>
      <description>I recently started moving some builds from TeamCity, Travis, and AppVeyor to GitHub actions, and while doing that, I thought I would also move to a more straightforward deployment process.</description>
      <a10:updated>2020-06-22T00:00:00Z</a10:updated>
    </item>
    <item>
      <guid isPermaLink="false">/blog/2016/12/azure-web-apps-and-the-certificate-store</guid>
      <link>https://patriksvensson.se/blog/2016/12/azure-web-apps-and-the-certificate-store</link>
      <title>Azure Web Apps and the certificate store</title>
      <description>I was trying to load a certificate from the certificate store in an Azure Web App today, and for some reason I could not find it via it's thumbprint. Since I thought I was looking in the wrong certificate store, I went to Kudu to take a closer look via the PowerShell debug console.</description>
      <a10:updated>2016-12-07T00:00:00Z</a10:updated>
    </item>
    <item>
      <guid isPermaLink="false">/blog/2014/06/the-singleton-logger</guid>
      <link>https://patriksvensson.se/blog/2014/06/the-singleton-logger</link>
      <title>The singleton logger</title>
      <description>It is widely accepted that you access logging frameworks via a static singleton instance, and most logging frameworks are designed to work like this. But why? Many people often refer to it as being a cross-cross cutting concern; and that it's therefore not important to do things by the book. Not only does most logging frameworks use the static singleton as a façade, but they also store process-wide state.</description>
      <a10:updated>2014-06-18T00:00:00Z</a10:updated>
    </item>
    <item>
      <guid isPermaLink="false">/blog/2014/07/its-not-a-party-without-cake</guid>
      <link>https://patriksvensson.se/blog/2014/07/its-not-a-party-without-cake</link>
      <title>It's not a party without Cake</title>
      <description>I have during my nine years as a (professional) programmer used several different build automation systems such as Rake, psake, CMake, TFS Build and FAKE, but none of these have allowed me to write my build scripts using C# - the language I use the most.</description>
      <a10:updated>2014-07-18T00:00:00Z</a10:updated>
    </item>
    <item>
      <guid isPermaLink="false">/blog/2019/09/how-to-find-a-nuget-package-path-from-msbuild</guid>
      <link>https://patriksvensson.se/blog/2019/09/how-to-find-a-nuget-package-path-from-msbuild</link>
      <title>How to find a NuGet package path from MSBuild</title>
      <description>Lately I've been porting some projects at a client from .NET Framework to .NET Core, and as part  of that I had to convert csproj files from the old project format to the new one. That means getting rid of package references in packages.config and replacing them with PackageReference elements in the project files.</description>
      <a10:updated>2019-09-30T00:00:00Z</a10:updated>
    </item>
    <item>
      <guid isPermaLink="false">/blog/2014/01/displaying-teamcity-build-status-on-github</guid>
      <link>https://patriksvensson.se/blog/2014/01/displaying-teamcity-build-status-on-github</link>
      <title>Displaying TeamCity build status on GitHub</title>
      <description>Have you ever wanted to display the current CI build status for a TeamCity project in your GitHub README? I did but couldn't find any good, straight forward information about how to do it. Turns out it's quite simple.</description>
      <a10:updated>2014-01-24T00:00:00Z</a10:updated>
    </item>
    <item>
      <guid isPermaLink="false">/blog/2018/04/an-introduction-to-spectre-cli</guid>
      <link>https://patriksvensson.se/blog/2018/04/an-introduction-to-spectre-cli</link>
      <title>An introduction to Spectre.Cli</title>
      <description>I've been writing a lot of CLI apps, both at work and in my free time, and there's never really been a command line parsing framework that has fitted my needs. While being either too complex or too simple, it's always nagged me that I need to write so much code myself. What I wanted was a way to be declarative about my commands, options and arguments while still allowing composition of them.</description>
      <a10:updated>2018-04-10T00:00:00Z</a10:updated>
    </item>
    <item>
      <guid isPermaLink="false">/blog/2020/03/how-to-write-a-stateful-roslyn-analyzer</guid>
      <link>https://patriksvensson.se/blog/2020/03/how-to-write-a-stateful-roslyn-analyzer</link>
      <title>How to write a stateful Roslyn analyzer</title>
      <description>I wrote a stateful Roslyn analyzer a couple of days ago to analyze the codebase at work for irregularities, and I thought I would share my findings on how I did it.</description>
      <a10:updated>2020-03-07T00:00:00Z</a10:updated>
    </item>
    <item>
      <guid isPermaLink="false">/blog/2019/12/roaming-profiles-with-windows-terminal</guid>
      <link>https://patriksvensson.se/blog/2019/12/roaming-profiles-with-windows-terminal</link>
      <title>Roaming profiles with Windows Terminal</title>
      <description>If you have more than one computer that you use, you might have noticed that it requires some work to keep your Windows Terminal profile up to date.</description>
      <a10:updated>2019-12-02T00:00:00Z</a10:updated>
    </item>
    <item>
      <guid isPermaLink="false">/blog/2014/11/cake-and-appveyor-integration</guid>
      <link>https://patriksvensson.se/blog/2014/11/cake-and-appveyor-integration</link>
      <title>Cake and AppVeyor integration</title>
      <description>In this blog post I will show you how to use Cake with your AppVeyor CI builds.</description>
      <a10:updated>2014-11-23T00:00:00Z</a10:updated>
    </item>
    <item>
      <guid isPermaLink="false">/blog/2014/08/script-aliases</guid>
      <link>https://patriksvensson.se/blog/2014/08/script-aliases</link>
      <title>Script aliases</title>
      <description>Cake supports something called script aliases. Script aliases are convenience methods that are easily accessible directly from a Cake script. Every API method in Cake is implemented like this.</description>
      <a10:updated>2014-08-19T00:00:00Z</a10:updated>
    </item>
    <item>
      <guid isPermaLink="false">/blog/2019/03/build-counters-in-azure-devops</guid>
      <link>https://patriksvensson.se/blog/2019/03/build-counters-in-azure-devops</link>
      <title>Using build counters in Azure DevOps</title>
      <description>We recently migrated some builds from TeamCity to Azure DevOps at my client, and couldn't find a feature analog to TeamCity's %build.counter% which we've been using to get automatically incremented version numbers for artifacts.</description>
      <a10:updated>2019-03-13T00:00:00Z</a10:updated>
    </item>
    <item>
      <guid isPermaLink="false">/blog/2021/12/intellisense-for-your-github-action-workflows</guid>
      <link>https://patriksvensson.se/blog/2021/12/intellisense-for-your-github-action-workflows</link>
      <title>Intellisense for your GitHub Actions workflows</title>
      <description>Although I'm a big fan of GitHub, I'm not a big fan of YAML. When it comes to orchestrating my builds, I usually prefer some kind of build script, but bootstrapping that build script is a necessary evil so we're stuck with YAML for that part.</description>
      <a10:updated>2021-12-22T00:00:00Z</a10:updated>
    </item>
    <item>
      <guid isPermaLink="false">/blog/2023/11/building-an-iterator-in-swift</guid>
      <link>https://patriksvensson.se/blog/2023/11/building-an-iterator-in-swift</link>
      <title>Building an iterator in Swift</title>
      <description>As part of learning Swift, I decided to port my project Spectre.Console (written in C#) to Swift.</description>
      <a10:updated>2023-11-13T00:00:00Z</a10:updated>
    </item>
    <item>
      <guid isPermaLink="false">/blog/2017/08/never-mutate-state-in-a-debug-assert-call</guid>
      <link>https://patriksvensson.se/blog/2017/08/never-mutate-state-in-a-debug-assert-call</link>
      <title>Never mutate state in a Debug.Assert call</title>
      <description>Yesterday I encountered a bug in a library I'm working on that only seemed to occur when compiled in release mode.</description>
      <a10:updated>2017-08-02T00:00:00Z</a10:updated>
    </item>
    <item>
      <guid isPermaLink="false">/blog/2013/12/binarywriter-and-cplusplus</guid>
      <link>https://patriksvensson.se/blog/2013/12/binarywriter-and-cplusplus</link>
      <title>BinaryWriter and C++</title>
      <description>A while back I had to read string data written by .NET's BinaryWriter in C++. I was initially a little bit confused about how the data was written but after using Reflector it turned out that the write method prefixes the string with a 7-bit encoded integer.</description>
      <a10:updated>2013-12-16T00:00:00Z</a10:updated>
    </item>
    <item>
      <guid isPermaLink="false">/blog/2014/04/introducing-lunt</guid>
      <link>https://patriksvensson.se/blog/2014/04/introducing-lunt</link>
      <title>Introducing Lunt</title>
      <description>Last summer, a friend and I started to write a little Paradroid clone. Since my only real experience as a game programmer was with XNA and MonoGame, I had grown fond of the XNA Content Pipeline, and naturally wanted something similar for this project.</description>
      <a10:updated>2014-04-05T00:00:00Z</a10:updated>
    </item>
    <item>
      <guid isPermaLink="false">/blog/2017/12/conditionals-in-xaml</guid>
      <link>https://patriksvensson.se/blog/2017/12/conditionals-in-xaml</link>
      <title>Conditionals in XAML</title>
      <description>Ever wanted to display things conditionally in XAML based on a pre-processor directive like `DEBUG`?</description>
      <a10:updated>2017-12-03T00:00:00Z</a10:updated>
    </item>
    <item>
      <guid isPermaLink="false">/blog/2017/11/using-embedded-resources-in-xunit-tests</guid>
      <link>https://patriksvensson.se/blog/2017/11/using-embedded-resources-in-xunit-tests</link>
      <title>Using embedded resources in xUnit tests</title>
      <description>I was reading Andrew Lock's excellent blog post about Creating parameterised tests in xUnit when I remembered something I wrote a while back that has proven to be quite useful.</description>
      <a10:updated>2017-11-11T00:00:00Z</a10:updated>
    </item>
    <item>
      <guid isPermaLink="false">/blog/2013/08/how-to-dynamically-add-attributes-to-a-class-with-castle-core</guid>
      <link>https://patriksvensson.se/blog/2013/08/how-to-dynamically-add-attributes-to-a-class-with-castle-core</link>
      <title>How to dynamically add attributes to a class with Castle.Core</title>
      <description>Yesterday I was working on some unit tests that ensured that some user derived classes passed to a method were decorated with a specific attribute.</description>
      <a10:updated>2013-08-15T00:00:00Z</a10:updated>
    </item>
    <item>
      <guid isPermaLink="false">/blog/2017/12/binding-to-a-richtextbox-in-wpf</guid>
      <link>https://patriksvensson.se/blog/2017/12/binding-to-a-richtextbox-in-wpf</link>
      <title>Binding to a RichTextBox in WPF</title>
      <description>I've been doing some WPF development the last couple of weeks, and one thing that bugged me was that there is no way (as far as I know) to bind content to a RichTextBox. This makes it kind of difficult to follow the MVVM pattern since the view model needs intimate knowledge of the view.</description>
      <a10:updated>2017-12-11T00:00:00Z</a10:updated>
    </item>
    <item>
      <guid isPermaLink="false">/blog/2025/07/introducing-open-cli</guid>
      <link>https://patriksvensson.se/blog/2025/07/introducing-open-cli</link>
      <title>Introducing OpenCLI</title>
      <description>About three years ago, I was invited to meetings with the System.CommandLine team at Microsoft. They were in the process of finalizing System.CommandLine and wanted input from people in the community, and I was included due to my work on Spectre.Console and Spectre.Console.Cli.</description>
      <a10:updated>2025-07-07T00:00:00Z</a10:updated>
    </item>
    <item>
      <guid isPermaLink="false">/blog/2013/08/culture-agnostic-string-comparisons</guid>
      <link>https://patriksvensson.se/blog/2013/08/culture-agnostic-string-comparisons</link>
      <title>Culture agnostic string comparisons</title>
      <description>Something I've seen a lot at different clients is naive string comparison. The most common case is to do something involving String.ToLower() on both strings that are being compared and then an equality comparison of the result.</description>
      <a10:updated>2013-08-22T00:00:00Z</a10:updated>
    </item>
    <item>
      <guid isPermaLink="false">/blog/2020/05/targeting-arm-for-windows-in-rust</guid>
      <link>https://patriksvensson.se/blog/2020/05/targeting-arm-for-windows-in-rust</link>
      <title>Targeting ARM64 for Windows in Rust</title>
      <description>I wanted to run a thing I'm building with Rust on my Surface Pro X which is an ARM64 device the other day. My initial thought when I got the idea, was "I hope it's not complicated to do".</description>
      <a10:updated>2020-05-26T00:00:00Z</a10:updated>
    </item>
    <item>
      <guid isPermaLink="false">/blog/2020/06/enumerating-monitors-in-rust-using-win32-api</guid>
      <link>https://patriksvensson.se/blog/2020/06/enumerating-monitors-in-rust-using-win32-api</link>
      <title>Enumerating monitors in Rust using Win32 API</title>
      <description>I had to enumerate all monitors yesterday using the EnumDisplayMonitors Win32 function, and I thought I would write a couple of lines about what I did since I couldn't find any useful information about how to do this.</description>
      <a10:updated>2020-06-08T00:00:00Z</a10:updated>
    </item>
    <item>
      <guid isPermaLink="false">/blog/2018/02/debugging-rust-on-windows-using-vscode</guid>
      <link>https://patriksvensson.se/blog/2018/02/debugging-rust-on-windows-using-vscode</link>
      <title>Debugging Rust on Windows using Visual Studio Code</title>
      <description>I recently wanted to debug a Rust program on Windows that I had written, and was struggling with how to get it to work. Since there was quite a lot of hoops to jump through to get it to work, I though I should share it with other people as well. I've written this blog post from memory and I'm far from an expert in LLVM or Rust, so if you see something strange here then let me know.</description>
      <a10:updated>2018-02-01T00:00:00Z</a10:updated>
    </item>
    <item>
      <guid isPermaLink="false">/blog/2019/06/debugging-an-uwp-store-app-with-windbg</guid>
      <link>https://patriksvensson.se/blog/2019/06/debugging-an-uwp-store-app-with-windbg</link>
      <title>Debugging an UWP store app with WinDbg</title>
      <description>I was encountering a rather irritating bug a couple of days ago that only manifested itself when built via the native toolchain in release mode. I couldn't get it to manifest itself when running from Visual Studio for some reason and the problem occurred so early in the app's lifecycle that I didn't have time to create a minidump of the process.</description>
      <a10:updated>2019-06-27T00:00:00Z</a10:updated>
    </item>
    <item>
      <guid isPermaLink="false">/blog/2020/03/creating-release-artifacts-with-github-actions</guid>
      <link>https://patriksvensson.se/blog/2020/03/creating-release-artifacts-with-github-actions</link>
      <title>How to create .NET Core release artifacts with GitHub Actions</title>
      <description>In this blog post, we'll create a GitHub Action that triggers each time a release is published, builds a binary on three different build agents (Windows, macOS, and Ubuntu), and attaches the compressed artifacts to the release.</description>
      <a10:updated>2020-03-22T00:00:00Z</a10:updated>
    </item>
  </channel>
</rss>