Skip to content

Instantly share code, notes, and snippets.

View CrazyTim's full-sized avatar

CrazyTim

  • Melbourne, Australia
View GitHub Profile
@mjebrahimi
mjebrahimi / EF Core - FromSql - ExecuteSqlCommand.md
Created March 19, 2021 18:16
EF Core - FromSql - ExecuteSqlCommand

Executing Raw SQL Queries

Entity Framework Core provides mechanisms for executing raw SQL queries directly against the database in circumstances where you cannot use LINQ to represent the query (e.g. a Full Text Search), if the generated SQL is not efficient enough, if you want to make use of existing stored procedures, or if you just prefer to write your own queries in SQL.

Entity Framework Core provides mechanisms

  • FromSql
    • FromSqlRaw (EF Core 3.0)
@rsp
rsp / GitHub-Project-Guidelines.md
Last active October 14, 2025 10:43
Git Strict Flow and GitHub Project Guidelines - setup rules and git flow for commercial and open-source projects by @rsp

Git Strict Flow and GitHub Project Guidelines

Or how to turn this:

into this:

@bcnzer
bcnzer / postman-pre-request.js
Last active April 16, 2025 06:21
Postman pre-request script to automatically get a bearer token from Auth0 and save it for reuse
const echoPostRequest = {
url: 'https://<my url>.auth0.com/oauth/token',
method: 'POST',
header: 'Content-Type:application/json',
body: {
mode: 'application/json',
raw: JSON.stringify(
{
client_id:'<your client ID>',
client_secret:'<your client secret>',
@joshbuchea
joshbuchea / semantic-commit-messages.md
Last active October 16, 2025 21:28
Semantic Commit Messages

Semantic Commit Messages

See how a minor change to your commit message style can make you a better programmer.

Format: <type>(<scope>): <subject>

<scope> is optional

Example

@joyrexus
joyrexus / README.md
Last active June 12, 2025 20:55
collapsible markdown

collapsible markdown?

CLICK ME

yes, even hidden code blocks!

print("hello world!")
var i = window.setInterval(function(){
for(let k of Object.keys(ig.game.targets)){ if(ig.game.targets[k]) for(let t of ig.game.targets[k]){ ig.game.shoot(k); for(let c of t.remainingWord){ ig.game.shoot(c); }; }; };
}, 200);
//window.clearInterval(i);
@PurpleBooth
PurpleBooth / README-Template.md
Last active October 15, 2025 18:55
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

@charliepark
charliepark / gist:4266921
Created December 12, 2012 10:58
You can use arrays and hashes in HTML5 data attributes. Use JSON.parse, and make sure you're using single quotes around the brackets and double quotes inside the brackets.
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
</head>
<body>
<div id="animals" data-animals='["cat", "dog", "bird"]'></div>
<div id="vehicles" data-vehicles='{"motorcycle":"Harley", "car":"Herbie", "steamshovel":"Mike"}'></div>
@aadnk
aadnk / ScannerForm.vb
Created September 7, 2012 17:21
A Port Scanner in VB.NET 2012
Imports System.Net.Sockets
Public Class ScannerForm
' Used to carry information from our fibers
Public Class PortState
Public Property PortNumber As Integer
Public Property IsOpen As Boolean
Public Sub New(open As Boolean, port As Integer)