Skip to content

Instantly share code, notes, and snippets.

@terrajobst
terrajobst / SplitByNamespace.cs
Created July 10, 2018 23:36
Split files by namespace
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis.CSharp;
using Microsoft.CodeAnalysis.CSharp.Syntax;
using Microsoft.CodeAnalysis.Text;
using System.Collections.Generic;
using System.IO;
using System.Linq;
namespace NetStandardCleanup
@davidfowl
davidfowl / Example1.cs
Last active March 28, 2024 20:36
How .NET Standard relates to .NET Platforms
namespace Analogy
{
/// <summary>
/// This example shows that a library that needs access to target .NET Standard 1.3
/// can only access APIs available in that .NET Standard. Even though similar the APIs exist on .NET
/// Framework 4.5, it implements a version of .NET Standard that isn't compatible with the library.
/// </summary>INetCoreApp10
class Example1
{
public void Net45Application(INetFramework45 platform)
@KirkMunro
KirkMunro / PowerShell.Signed.gitattributes
Last active February 15, 2023 10:24
.gitattributes file contents for PowerShell script or manifest modules (signed or unsigned) and binary modules
# Treat all files in this project as binary. This enables atomic
# checkins (no merges, these are signed files) and it preserves
# CRLF line endings
* binary