Skip to content

Instantly share code, notes, and snippets.

View binki's full-sized avatar

Nathan Phillip Brink binki

View GitHub Profile
@binki
binki / 떡볶이-recipe.md
Last active October 24, 2022 00:11
떡볶이 (ddeokbokki) recipe from 김한솔

Source: transcript from a discord channel

Ingredients

Main

  • 1lb (450g) Rice cakes (1.5in long (thumb length)) (I tried 300g once but there was too much sauce)
  • 0.33lb (150g) fish cakes (4×4in 2.5 layers?—half as much as there is ddeok)
  • 1 onion
  • 1 carrot
  • 1 cup sliced cabbage (optional)
@binki
binki / apps-or-websites-i-cannot-use-with-google-voice.md
Last active September 25, 2022 19:52
Apps or websites I can't use with Google Voice
  • BeReal. I guess I can't try last year's (this written in 2022) social media trend. (Though I can't tell if this app is just failing to use Android WebView correctly since I'm a Firefox user).
  • Venmo. Since I was forced, I'm just using one of my phones' SIM's numbers. But I wish people were willing to accept PayPal instead which is free for personal use and international and supports using a desktop web interface. So few things to like about Venmo!
  • Viber. There's a chance that if you open a support request they might override it for you, but nobody uses it anyway. Sorry, Rakuten.
@binki
binki / DictionaryReaderProgram.cs
Last active February 15, 2022 20:38
An example of an IDictionaryReader interface which could be used to support IDictionary<TKey, TValue> and IReadOnlyDictionary<TKey, TValue> with no transient object creation
using System;
using System.Collections.Generic;
using System.Linq;
// Proof that this makes the compiler happy.
// See https://stackoverflow.com/a/34998637
class Program
{
static void Main(string[] args)
{
@binki
binki / ConstrainedValueTypeDictionaryAdapterProgram.cs
Last active February 15, 2022 20:38
An example of how to adapt IDictionary<TKey, TValue> as IReadOnlyDictionary<TKey, TValue> without incurring an object instantiation using value types
using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
// Proof that this makes the compiler happy.
// See https://stackoverflow.com/a/34998637
class Program
{
static void Main(string[] args)
@binki
binki / addUseStrict.js
Last active February 9, 2022 12:06
jscodeshift codemod to add "use strict" to any file where it is not already the first statement
module.exports = function (fileInfo, {
jscodeshift,
}, options) {
// Work around for https://github.com/facebook/jscodeshift/issues/262
const isUnix = fileInfo.source.indexOf('\r\n') === -1;
const dom = jscodeshift(fileInfo.source);
const topLevelStatements = jscodeshift(dom.get('program', 'body').value).filter(path => {
return jscodeshift.Statement.check(path.node);
});
// Don’t add another one if it is already there.
@binki
binki / Program.cs
Created July 28, 2016 13:47
Fun with C# expressions and maybe a way to SQL?
using System;
using System.Linq;
using System.Linq.Expressions;
namespace ExpressionsFun
{
static class Program
{
static void Main(string[] args)
{
@binki
binki / oyakodon-recipe.md
Last active January 19, 2022 16:36
Oyakodon Recipe (親子丼)
@binki
binki / invoke-mailman.sh
Created January 6, 2022 02:24
Set mailing list moderator password mailman3
mailman -C /etc/mailman/mailman.cfg withlist -l list@example.org
@binki
binki / carbonara.md
Last active September 9, 2021 02:14
Carbonara (Modern wth Garlic)

Modern Carbonara

Source: The second half, modern, from https://youtube.com/watch?v=qoHnwOHLiMk

Ingredients

  • 1 cup grated parmesan cheese (about a third of an 8oz wedge (i.e., 2⅔oz ungrated cheese) becomes a cup when grated).
  • ½ cup grated Romano cheese (so get 1+1/3oz ungrated cheese).
  • 3 eggs
  • 1 egg yolk (for a total of 4 egg yolks and 3 egg whites)
  • ½ tsp ground black pepper
@binki
binki / permissions-for-SqlDependency.md
Last active June 28, 2021 00:25
Permissions for SqlDependency

Permissions for SqlDependency

Issues With Original Post

This is derived from the original post. However, the original post has two issues. Both of these issues are related to the SqlDependencySchemaOwner user it creates in the database. This user owns and executes the stored procedures which SqlDependency creates dynamically.

Microsoft archived that forum and even the original author cannot update the post.