Skip to content

Instantly share code, notes, and snippets.

View Keboo's full-sized avatar

Kevin B Keboo

View GitHub Profile
View bools_are_fun.cs
using System;
static class Program
static void Main(string[] args)
bool b = GetTricksyBool();
if (b) Console.WriteLine(b.IsTrue());
static bool IsTrue(this bool b)
jamesmontemagno /
Last active September 5, 2022 16:28
Live Streaming Kit

Here is my live stream setup kit :)

If you are doing a personal stream, I recommend only streaming to a single service such as Twitch. It is better for community building and easier on the streamer. Additionally, if you become an affiliate you are locked into a platform anyways.

How my setup works is that I have my main Desktop PC that has my streaming software, chat, alerts, music, and such all running on it. I have a second surface book that has HDMI out into the capture card in my Desktop PC. I do this because often when you compile apps it may freeze up your computer and stream :(. I have 2 sets of keyboards and mice and 2 monitors that I work off of. This works for me, but you do you :)


  • OBS: Your main go to for streaming software. It works on every OS :). If you want something with everything baked in take a look at Streamlabs OBS.
  • Streamlabs has all of your pop ups for subscribers and such on t
punker76 / MainWindow.xaml
Created February 6, 2019 20:36
Detecting Windows 10 Dark/Light mode
View MainWindow.xaml
<Window x:Class="WpfApp1.MainWindow"
Title="MainWindow" Height="450" Width="800">
jespersh / MaterialDesignTheme.TabControl.xaml
Created December 6, 2018 14:19
Tabcontrol and tabitem for MaterialDesignTheme
View MaterialDesignTheme.TabControl.xaml
<ResourceDictionary xmlns=""
<Style x:Key="MaterialDesignTabControl" TargetType="{x:Type TabControl}">
<Setter Property="BorderThickness" Value="1" />
<Style x:Key="MaterialDesignTabItem" TargetType="{x:Type TabItem}">
<Setter Property="Background" Value="{DynamicResource MaterialDesignBackground}" />
DustinCampbell /
Created April 10, 2018 21:36
Using MSBuildWorkspace


Roslyn provides a rich set of APIs for analyzing C# and Visual Basic source code, but constructing a context in which to perform analysis can be challenging. For simple tasks, creating a Compilation populated with SyntaxTrees, MetadataReferences and a handful of options may suffice. However, if there are multiple projects involved in the analysis, it is more complicated because multiple Compilations need to be created with references between them.

To simplify the construction process. Roslyn provides the Workspace API, which can be used to model solutions, projects and documents. The Workspace API performs all of the heavy lifting needed to parse SyntaxTrees from source code, load MetadataReferences, and construct Compilations and add references between them.

yohhoy / ff2cv.cpp
Last active November 12, 2023 11:17
Read video frame with FFmpeg and convert to OpenCV image
View ff2cv.cpp
* Read video frame with FFmpeg and convert to OpenCV image
* Copyright (c) 2016 yohhoy
#include <iostream>
#include <vector>
// FFmpeg
extern "C" {
#include <libavformat/avformat.h>
piscisaureus /
Created August 13, 2012 16:12
Checkout github pull requests locally

Locate the section for your github remote in the .git/config file. It looks like this:

[remote "origin"]
	fetch = +refs/heads/*:refs/remotes/origin/*
	url =

Now add the line fetch = +refs/pull/*/head:refs/remotes/origin/pr/* to this section. Obviously, change the github url to match your project's URL. It ends up looking like this:

Ciantic / keyboardlistener.cs
Created July 11, 2010 17:33
C# Keyboard listener
View keyboardlistener.cs
using System;
using System.Diagnostics;
using System.Runtime.InteropServices;
using System.Runtime.CompilerServices;
using System.Windows.Input;
using System.Windows.Threading;
using System.Collections.Generic;
namespace Ownskit.Utils