CustomCode.Analyzer
0.1.1
See the version list below for details.
dotnet add package CustomCode.Analyzer --version 0.1.1
NuGet\Install-Package CustomCode.Analyzer -Version 0.1.1
<PackageReference Include="CustomCode.Analyzer" Version="0.1.1"> <PrivateAssets>all</PrivateAssets> <IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets> </PackageReference>
<PackageVersion Include="CustomCode.Analyzer" Version="0.1.1" />
<PackageReference Include="CustomCode.Analyzer"> <PrivateAssets>all</PrivateAssets> <IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets> </PackageReference>
paket add CustomCode.Analyzer --version 0.1.1
#r "nuget: CustomCode.Analyzer, 0.1.1"
#:package CustomCode.Analyzer@0.1.1
#addin nuget:?package=CustomCode.Analyzer&version=0.1.1
#tool nuget:?package=CustomCode.Analyzer&version=0.1.1
OutSystems Developer Cloud (ODC) Custom Code Analyzer
ℹ️ This component is unofficial and unsupported by OutSystems.
Overview
When you want to extend your ODC apps with custom C# code, you do so with the External Libraries SDK. This SDK allows you to write C# code that you can call from your ODC apps.
Although IntelliSense in your IDE guides the available SDK decorators and their syntax, it does not guide the rules you must follow (for example, on naming and design decisions). This guidance is provided when uploading your project's built assembly to the ODC Portal, where you get feedback on rule violations. Using this component brings that feedback forward and gives you real-time feedback on compliance with the rules as you write the code.
Technical Primer
When you upload your project's built assembly to the ODC Portal, it does not have access to the underlying code—the ODC Portal checks compliance with the rules using the assembly's metadata.
This extension, built from scratch, implements the rules using the rich code analysis APIs of Roslyn, the .NET compiler.
How to use
Visual Studio 2022 (Enterprise, Pro and Community editions)
You can use the auto-updating extension from the Visual Studio Marketplace. Simply install the extension from the Visual Studio Marketplace.
If your project references the External Libraries SDK (OutSystems.ExternalLibraries.SDK
), the extension should automatically start providing feedback on your code.
Others
Add the NuGet package as a dev dependency to your ODC external libraries project:
dotnet add package CustomCode.Analyzer
If your project references the External Libraries SDK (OutSystems.ExternalLibraries.SDK
), the component should automatically start providing feedback on your code.
💡 Auto-updating extensions for Visual Studio Code and Rider are in the works.
TODO
- Marketplace extensions for Visual Studio Code and Rider.
- Beyond the rules: info-level guidance for best practices (statelessness checks, guidance on large binary files).
- Explore viability of implementing OS-ELG-MODL-05009
- Explore
CodeFixProvider
for auto-fixable rules.
Contributing
Please report bugs and feature requests here.
PRs are welcome. Code quality improvements, features (especially those in the TODO list) and documentation improvements are all welcome 🤗 All changes to Analyzer code should pass all existing tests (dotnet test
) and all new features should be comprehensively covered by new tests.
Learn more about Target Frameworks and .NET Standard.
-
.NETStandard 2.0
- No dependencies.
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.