2024-06-03
This commit is contained in:
		
							
								
								
									
										48
									
								
								_-Review/c-sharp.md
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										48
									
								
								_-Review/c-sharp.md
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,48 @@ | ||||
| --- | ||||
| type: "topic" | ||||
| assigned: "" | ||||
| created: "2024-01-06T01:25:36.085Z" | ||||
| updated: "2024-01-06T01:25:36.085Z" | ||||
| --- | ||||
|  | ||||
| # C Sharp | ||||
|  | ||||
| ```bash | ||||
| dotnet add package runtime.win-x64.Microsoft.DotNet.ILCompiler --version 7.0.7 | ||||
| dotnet publish -r win-x64 -c Release -p:PublishAot=true --source https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet7/nuget/v3/index.json | ||||
| ``` | ||||
|  | ||||
| ```C# | ||||
| internal partial class AppSettingsSourceGenerationContext : JsonSerializerContext | ||||
| ``` | ||||
|  | ||||
| - [x] File-Folder-Helper | ||||
| - [x] View-by-Distance-MKLink-Console/Rename | ||||
|  | ||||
| ```C# | ||||
| void Do(Action? tick) | ||||
| ``` | ||||
|  | ||||
| - [x] View-by-Distance-MKLink-Console/CopyDistinct | ||||
|  | ||||
| ```C# | ||||
| public interface IMetadata<T> { } | ||||
| public class B_Metadata : IMetadata<MetadataExtractor.Directory> { int IMetadata<MetadataExtractor.Directory>.GetInt() => 1; } | ||||
| ``` | ||||
|  | ||||
| - [x] View-by-Distance-MKLink-Console/Property | ||||
|  | ||||
| ```bash | ||||
| C:\Windows\System32\Config\SystemProfile\AppData\Roaming\Microsoft\UserSecrets | ||||
| ``` | ||||
|  | ||||
| ```C# | ||||
| IConfigurationSection[] configurationSections = configurationRoot.GetChildren().ToArray(); | ||||
| foreach (IConfigurationSection configurationSection1 in configurationSections) | ||||
| { | ||||
|     if (configurationSection1.GetChildren().ToArray().Length > 1) | ||||
|         continue; | ||||
| } | ||||
| string text = configurationRoot.GetDebugView(); | ||||
| File.WriteAllText(".txt", text); | ||||
| ``` | ||||
		Reference in New Issue
	
	Block a user