Skip to content

Instantly share code, notes, and snippets.

View goncalo-oliveira's full-sized avatar

Goncalo Oliveira goncalo-oliveira

View GitHub Profile
@goncalo-oliveira
goncalo-oliveira / Startup.cs
Last active August 11, 2021 11:43
Configuring JsonOptions with ASPNET Functions
namespace OpenFaaS
{
public class Startup
{
...
public void ConfigureServices( IServiceCollection services )
{
/*
we don't have access to IMvcBuilder to use .AddJsonOptions extensions
[
{
"id": 1,
"name": "John Doe",
},
{
"id": 2,
"name": "Jane Doe",
},
{
@goncalo-oliveira
goncalo-oliveira / git-cheat-sheet.md
Last active February 6, 2023 09:18
Git Cheat Sheet

Git Cheat Sheet

This document provides a few shortcuts to Git commands.

Config

Retrieve origin url

git config --get remote.origin.url
@goncalo-oliveira
goncalo-oliveira / ParallelAsync.cs
Last active April 2, 2021 03:36
Async Parallel.ForEach
using System;
using System.Collections.Concurrent;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
namespace MyNamespace
{
public static class ParallelAsync
{