Skip to content

Instantly share code, notes, and snippets.

View LwServices's full-sized avatar
🏠
Working from home

Lech Wiecierzynski LwServices

🏠
Working from home
View GitHub Profile
@LwServices
LwServices / DI WPF-C#.md
Created June 27, 2022 16:35 — forked from sajidmohammed88/DI WPF-C#.md
Dependency injection in WPF project with .net core

Dependency injection in WPF project with .net core

Delete StartupUri="MainWindow.xaml" from App.xaml
Install packages :
Microsoft.Extensions.Configuration.Json
Microsoft.Extensions.DependencyInjection
Microsoft.Extensions.Options.ConfigurationExtensions
Add the file appsettings.json in the root of the project to use it for configuration.
@LwServices
LwServices / Windows Defender Exclusions for Developer.ps1
Created August 11, 2019 05:07 — forked from odornauf/Windows Defender Exclusions for Developer.ps1
Adds Windows Defender exclusions for developers (Visual Studio, JetBrains Rider, IntellIJ Idea, Git, MsBuild, dotnet, mono etc.)
$userPath = $env:USERPROFILE
$pathExclusions = New-Object System.Collections.ArrayList
$processExclusions = New-Object System.Collections.ArrayList
$pathExclusions.Add('C:\Windows\Microsoft.NET') > $null
$pathExclusions.Add('C:\Windows\assembly') > $null
$pathExclusions.Add($userPath + '\AppData\Local\Microsoft\VisualStudio') > $null
$pathExclusions.Add('C:\ProgramData\Microsoft\VisualStudio\Packages') > $null
$pathExclusions.Add('C:\Program Files (x86)\MSBuild') > $null
$pathExclusions.Add('C:\Program Files (x86)\Microsoft Visual Studio 14.0') > $null
@LwServices
LwServices / ObservableDictionary.cs
Created August 4, 2017 07:53 — forked from kzu/ObservableDictionary.cs
An ObservableDictionary<TKey, TValue>
using System;
using System.Collections;
using System.Collections.Generic;
using System.Collections.Specialized;
using System.ComponentModel;
using System.Diagnostics;
using System.Dynamic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;