Skip to content

Instantly share code, notes, and snippets.

View mouadcherkaoui's full-sized avatar
🎯
Focusing

Mouad Cherkaoui mouadcherkaoui

🎯
Focusing
View GitHub Profile
00:000 00:000 OC: OpenCore DBG-065-2020-12-24 is loading in Optional mode (0/0)...
00:075 00:075 OC: Boot timestamp - 2020.12.24 20:37:59
00:159 00:083 OCCPU: MP services threads 8 (enabled 8) - Success
00:235 00:076 OCCPU: MP services Pkg 1 Cores 4 Threads 2 - Success
00:311 00:075 OCCPU: Found Intel(R) Core(TM) i7-1065G7 CPU @ 1.30GHz
00:387 00:075 OCCPU: Signature 706E5 Stepping 5 Model 7E Family 6 Type 0 ExtModel 7 ExtFamily 0 uCode A0
00:469 00:082 OCCPU: EIST CFG Lock 0
00:543 00:073 OCCPU: Ratio Min 4 Max 15 Current 35 Turbo 39 38 35 35
00:617 00:073 OCCPU: TSC Adjust 0
00:699 00:082 OCCPU: Queried Core Crystal Clock Frequency 38400000Hz
using System;
using System.Collections.Generic;
using System.Text;
using System.Linq;
using Microsoft.Azure.Management.Fluent;
using Microsoft.Azure.Management.Network;
using Microsoft.Azure.Management.Network.Fluent;
namespace AzureManagmentExample
{
Get-PnpDevice -FriendlyName *webcam*
Get-PnpDevice -FriendlyName *webcam* -Class Camera,image
Disable-PnpDevice -InstanceId (Get-PnpDevice -FriendlyName *webcam* -Class Image -Status OK).InstanceId
Disable-PnpDevice -InstanceId (Get-PnpDevice -FriendlyName *webcam* -Class Camera -Status OK).InstanceId
Enable-PnpDevice -InstanceId (Get-PnpDevice -FriendlyName *webcam* -Class Image -Status Error).InstanceId
Enable-PnpDevice -InstanceId (Get-PnpDevice -FriendlyName *webcam* -Class Camera -Status Error).InstanceId
#search and list all missing Drivers
$Session = New-Object -ComObject Microsoft.Update.Session
$Searcher = $Session.CreateUpdateSearcher()
$Searcher.ServiceID = '7971f918-a847-4430-9279-4a52d1efe18d'
$Searcher.SearchScope = 1 # MachineOnly
$Searcher.ServerSelection = 3 # Third Party
$Criteria = "IsInstalled=0 and Type='Driver' and ISHidden=0"
@mouadcherkaoui
mouadcherkaoui / Program.cs
Created July 13, 2020 16:19 — forked from miteshsureja/Program.cs
How to execute PowerShell script or cmdlets from C# code?
using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Diagnostics;
using System.Linq;
using System.Management.Automation;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
<Window x:Class="DataGridCheckBox.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:local="clr-namespace:DataGridCheckBox"
mc:Ignorable="d"
Title="MainWindow" Height="450" Width="800">
<Window.DataContext>
<local:MainWindowViewModel></local:MainWindowViewModel>
@mouadcherkaoui
mouadcherkaoui / Sample.fsproj
Created March 27, 2020 11:24 — forked from awright18/Sample.fsproj
F# http reqeust with HttpClient
<Project Sdk="FSharp.NET.Sdk;Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>netcoreapp1.1</TargetFramework>
</PropertyGroup>
<ItemGroup>
<Compile Include="rss.fs" />
@mouadcherkaoui
mouadcherkaoui / gh-pages.md
Created March 20, 2020 05:50 — forked from ramnathv/gh-pages.md
Creating a clean gh-pages branch

Creating a clean gh-pages branch

This is the sequence of steps to follow to create a root gh-pages branch. It is based on a question at [SO]

cd /path/to/repo-name
git symbolic-ref HEAD refs/heads/gh-pages
rm .git/index
git clean -fdx
echo "My GitHub Page" &gt; index.html
@mouadcherkaoui
mouadcherkaoui / README-Template.md
Created February 16, 2020 20:32 — forked from PurpleBooth/README-Template.md
A template to make good README.md

Project Title

One Paragraph of project description goes here

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Prerequisites

@mouadcherkaoui
mouadcherkaoui / nuxtjs-nestjs.md
Created February 14, 2020 17:23 — forked from lewebsimple/nuxtjs-nestjs.md
NuxtJS / NestJS fullstack development

This is my take on fullstack development using NuxtJS and NestJS.

Development steps

  • Lerna monorepo
  • TypeScript linting and formatting
  • Minimal NestJS server
  • Minimal NuxtJS client
  • Environment configuration
  • TypeGraphQL
  • TypeORM / MySQL