Skip to content

Instantly share code, notes, and snippets.

Avatar

Stephen Shaw decriptor

View GitHub Profile
View gist:32ebe7ecb63b513bd62c0971e93bd7dc
Foo.csproj:
<Project Sdk="Microsoft.NET.Sdk.WindowsDesktop">
<PropertyGroup>
<OutputType>exe</OutputType>
<TargetFramework>netcoreapp3.1</TargetFramework>
<UseWindowsForms>true</UseWindowsForms>
</PropertyGroup>
View gist:d9788a31a9272422c522ef33dc558662
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace Day12
{
class PlantGenerations
{
public string InitialState { get; }
View gist:c9f01859dda794f7b1b0819e9d42818c
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks.Dataflow;
namespace SimpleProblems
{
class Program
{
static readonly IEnumerable<int> numbers = Enumerable.Range(1, 100);
View gist:9d25446af414cac1bd29f41c84052237
Could not load signature of ImageMagick.MagickImage:ToBitmapSource due to: Could not load file or assembly 'PresentationCore, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies.
Could not load signature of ImageMagick.IMagickImage:ToBitmapSource due to: Could not load file or assembly 'PresentationCore, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies.
Recolor<Rgba32>(provider: Png/CalliphoraPartial.png[Rgba32], sourceColorName: "Yellow", targetColorName: "Pink", threshold: 0.2) [FAIL]
System.TypeLoadException : Could not resolve the signature of a virtual method
Stack Trace:
at SixLabors.ImageSharp.Image+<>c__DisplayClass89_0`1[TPixel].<Load>b__0 (System.IO.Stream s) [0x00000] in <bd43945d254d4a1f9fdba1efa1b8f436>:0
at SixLabors.ImageSharp.Image.WithSeekableStream[T] (SixLabors.ImageSharp.Configuration config, System.IO.Stream stream, System.Func`2[T,TResult] action) [0x0003d] in <bd439
View gist:0123113637b88c627c18051c4e0f1971
enum GameState {
Damage = 1,
OtherDamage = 2,
SomethingElse = 3,
}
var state = GameState.OtherDamage;
switch (state) {
case GameState.Damage:
View gist:fcda6762dcbeca4e055243814fac01fc
### Set environment variables for Visual Studio Command Prompt
Push-Location 'C:\Program Files (x86)\Microsoft Visual Studio\16\Preview\Common7\Tools'
cmd /c "VsDevCmd.bat&set" |
ForEach-Object {
if ($_ -match "=") {
$v = $_.split("="); set-item -force -path "ENV:\$($v[0])" -value "$($v[1])"
}
}
Pop-Location
View gist:309f4d4f6c44099191ae4e858a89d8ab
sshaw@shawmsxamthree:~/Projects/monodevelop (fix-3717-geterrorsasync *)$ git diff
diff --git a/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Editor.Extension/ErrorHandlerTextEditorExtension.cs b/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Editor.Extension/ErrorHandlerTextEditorExtension.cs
index c84f597875..0772b23ec5 100644
--- a/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Editor.Extension/ErrorHandlerTextEditorExtension.cs
+++ b/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Editor.Extension/ErrorHandlerTextEditorExtension.cs
@@ -81,9 +81,13 @@ namespace MonoDevelop.Ide.Editor.Extension
var ctx = DocumentContext;
if (ctx == null)
return;
- await UpdateErrorUndelines (ctx, parsedDocument, token).ConfigureAwait (false);
View gist:1e9b26d6880b59f3220f91ad5ceca1b4
Stack trace:
at ObjCRuntime.Messaging.void_objc_msgSend_IntPtr_IntPtr_IntPtr (System.IntPtr , System.IntPtr , System.IntPtr , System.IntPtr , System.IntPtr ) [0x00000] in <3a4451518a52447793d7291f558d308b>:0
at AppKit.NSMenu.PopUpContextMenu (AppKit.NSMenu menu, AppKit.NSEvent theEvent, AppKit.NSView view) [0x00050] in /Users/builder/data/lanes/5143/416f778f/source/xamarin-macios/src/build/mac/full/AppKit/NSMenu.g.cs:1786
at Xwt.Mac.MenuBackend.Popup () [0x0000c] in /Users/sshaw/code/monodevelop/main/external/xwt/Xwt.XamMac/Xwt.Mac/MenuBackend.cs:69
at Xwt.Menu.Popup () [0x00001] in /Users/sshaw/code/monodevelop/main/external/xwt/Xwt/Xwt/Menu.cs:81
at Xamarin.Designer.DesignerService.DisplayPopup (Xamarin.Designer.DesignerCommandSet contextMenu, Xwt.Toolkit popupToolkit, Xwt.Toolkit dispatchToolkit) [0x0004e] in /Users/sshaw/code/designer/Xamarin.Designer/Xamarin.Designer/DesignerService.cs:76
at Xamarin.Designer.DesignerOutlinePanel.ShowContextMenu () [0x00001] in /Users/sshaw/code/designer
View gist:4df80720cf84d076ad186281363112d7
├── v2.3
│   ├── Mono.Android.Export.dll
│   ├── Mono.Android.Export.pdb
│   ├── Mono.Android.dll
│   ├── Mono.Android.pdb
│   ├── OpenTK-1.0.dll
│   ├── OpenTK-1.0.pdb
│   ├── OpenTK.dll
│   ├── OpenTK.pdb
│   ├── RedistList
View gist:c4236ee7b17d3806909308bddeec4941
/*
* tokenizer.c
*
* Created on: June 17, 2011
* Author: Stephen Shaw
*/
#include <stdio.h>
#include <stdlib.h>
#include <ctype.h>