Tag: Tips

Configuration in .Net Core 1.1 console project Blog

Almost every application needs some kind of config. We can store it in file, database or cloud. But have we got any solution to help us manage those configs? Configuration Configuration builder provides a way to manage name-value configuration even from multiple sources. As we can read from Microsoft there are configuration providers for: Files ex JSON, XML Command-line arguments Environment variables In-memory objects Encrypted user...

Read More

Changing author of the pushed git commit in opensource project Blog

Sometimes we have to change author of the pushed commit. How to do it without much efford? Today I stuck on similar problem. I was using SourceTree to commit some changes to be available on my second computer… Unfortunately I didn’t realise which user is associated with it. Just after push saw wrong author next to the commit. Because I’m not very familiar with console...

Read More

OrderBy with boolean value | How to put specific values on top of the list Blog

Hi there! I’ve just had to sort some list alphabetically with specific values on top. Here is one of the possible solution. Worth to know: OrderBy sorts items in ascending order [a, b, c, d] [1,2,3,4] Can be use with boolean function False = 0 True = 1 So if we use: Item that equals „Cat” will be placed as last element, because as the only element...

Read More