Skip to content

Instantly share code, notes, and snippets.

View yellis's full-sized avatar

Yaakov Ellis yellis

View GitHub Profile
@yellis
yellis / guidelines.md
Last active March 17, 2020 14:15
Israel MOH Guidelines 2020-03-17

Spokesman Office, Ministry of Health P.O.B 1176 Jerusalem 91010 dover@moh.health.gov.il Tel: 02-5081220/5 Fax: 02-5655965 21 Adar 5768 March 17, 2020 Reference: 159050420 [Unofficial translation by IMRA]

Ministry of Health announces: Ban on going to parks, malls, beach

@yellis
yellis / izkor.linq
Created November 7, 2018 22:17
LinqPad file to retrieve names from the Izkor.gov.il site, export to csv
<Query Kind="Program">
<NuGetReference>CsvHelper</NuGetReference>
<NuGetReference Prerelease="true">StackExchange.Utils.Http</NuGetReference>
<Namespace>CsvHelper</Namespace>
<Namespace>StackExchange.Utils</Namespace>
<Namespace>System.Threading.Tasks</Namespace>
<Namespace>System.Globalization</Namespace>
</Query>
async Task Main()
@yellis
yellis / curses.adoc
Last active August 29, 2015 14:03
@jimwebber best curses in @neo4j talk

Curses!

I heard Jim Webber (chief scientist of neo4j) give an intro talk for neo4j at the Sela Dev conference in TLV on 2014-07-01. I tweeted about Jim’s profligate use of expletives and was requested by his coworkers to elaborate. Though I can’t remember every single one (he averaged one curse every 2.5 minutes, though they tended to come in bursts), the graph below tries to reconstruct one sentence that stands out in my memory.

CREATE (jim:Person { name:"Jim" }),
       (shittiest:Curse { name:"Shittiest" }),
       (neo4j:Target { name:"neo4j",type:"graphDb" }),
// Bechmarking for http://stackoverflow.com/a/21903029/51
void Main()
{
var sourceList = source.Split(' ', '\n').ToList(); // 2582 items
long numSets = 10000000;
RunTest(sourceList, false, numSets);
RunTest(sourceList, true, numSets);
}
@yellis
yellis / gist:8955467
Last active February 11, 2019 22:51
Convert 15 Char Salesforce Id to 18 Char Salesforce Id
// Based on algorithm given at http://wp.me/pWWz3-14
static string Convert15CharTo18CharId(string id)
{
if (string.IsNullOrEmpty(id)) throw new ArgumentNullException("id");
if (id.Length == 18) return id;
if (id.Length != 15) throw new ArgumentException("Illegal argument length. 15 char string expected.", "id");
var triplet = new List<string> {id.Substring(0, 5), id.Substring(5, 5), id.Substring(10, 5)};
StringBuilder str = new StringBuilder(5);
string suffix = string.Empty;
VirtualBox 4.1.28 r89849 win.amd64 (Oct 11 2013 15:07:40) release log
00:00:03.862 Log opened 2013-11-09T18:33:05.763011400Z
00:00:03.862 OS Product: Windows 8
00:00:03.862 OS Release: 6.2.9200
00:00:03.862 OS Service Pack:
00:00:03.863 Host RAM: 32705MB RAM, available: 28066MB
00:00:03.863 Executable: C:\Program Files\Oracle\VirtualBox\VirtualBox.exe
00:00:03.863 Process ID: 8344
00:00:03.863 Package type: WINDOWS_64BITS_GENERIC
00:00:03.863 Installed Extension Packs:
Stephen B. Kaplitt
Member of the Bar in New York * New Jersey * Maryland * District of Columbia (inactive)
1271 Avenue of the Americas
Suite 4300
New York, NY 10020
www.KaplittLegal.com
June 17, 2013
VIA EMAIL ONLY
@yellis
yellis / gist:2028449
Created March 13, 2012 12:19
Error message when trying to load RavenAppender (from VS Debug Output)
=== Pre-bind state information ===
LOG: User = ...
LOG: DisplayName = log4net.Raven
(Partial)
WRN: Partial binding information was supplied for an assembly:
WRN: Assembly Name: log4net.Raven | Domain ID: 3
WRN: A partial bind occurs when only part of the assembly display name is provided.
WRN: This might result in the binder loading an incorrect assembly.
WRN: It is recommended to provide a fully specified textual identity for the assembly,
WRN: that consists of the simple name, version, culture, and public key token.