Skip to content

Instantly share code, notes, and snippets.

View m-jovanovic's full-sized avatar
🚀
Shipping code every day!

Milan Jovanović m-jovanovic

🚀
Shipping code every day!
View GitHub Profile
@m-jovanovic
m-jovanovic / Result.cs
Created September 7, 2023 08:03
Result type
public class Result
{
protected internal Result(bool isSuccess, Error error)
{
if (isSuccess && error != Error.None)
{
throw new InvalidOperationException();
}
if (!isSuccess && error == Error.None)
@m-jovanovic
m-jovanovic / .editorconfig
Created June 7, 2023 12:17
Sample editor config with a bunch of rules turned off 😅
root = true
# C# files
[*.cs]
#### Core EditorConfig Options ####
# Indentation and spacing
indent_size = 4
indent_style = space
@m-jovanovic
m-jovanovic / .editorconfig
Created May 16, 2023 10:50
A sample Editorconfig file for Visual Studio
[*.cs]
# IDE0058: Expression value is never used
dotnet_diagnostic.IDE0058.severity = none
# IDE0053: Use expression body for lambda expressions
dotnet_diagnostic.IDE0053.severity = none
csharp_indent_labels = one_less_than_current
csharp_using_directive_placement = outside_namespace:error
csharp_prefer_simple_using_statement = true:error
name: Publish Development 🚀
on:
workflow_dispatch:
push:
branches:
- main
env:
AZURE_WEBAPP_NAME: dev-api-trainersphere