Skip to content

Instantly share code, notes, and snippets.

View dterracino's full-sized avatar
🐢
I may be slow to respond…

David Terracino dterracino

🐢
I may be slow to respond…
View GitHub Profile
@ZacharyPatten
ZacharyPatten / Calculator.cs
Last active September 10, 2020 02:35
Calculator Example For C# Beginners
using System;
using System.Linq;
namespace Example
{
class Program
{
static string[] Operators = { "+", "-", "*", "/" };
static void Main()
@ZacharyPatten
ZacharyPatten / cdui.md
Last active September 10, 2020 02:35
Custom Windows keyword "cdui" to more easily change directories from the console written in C#.

This is a custom windows command to more easily change the directory in Windows consoles. Rather than typing out directory names you just use the arrow keys. Just build source to "cdui.exe" and add it to your PATH.

// cdui
//
// This program is intended to help users change directories more easily
// in the console. It provides a UI and lets you navigate with keypresses
// rather than having to type out directory names.
//
// Controls...
@ZacharyPatten
ZacharyPatten / sourceof.cs
Last active September 10, 2020 02:36
Experimenting with a "sourceof" operator similar to "nameof" but works on expressions...
using System;
using System.Linq.Expressions;
using System.Text.RegularExpressions;
using static Syntax;
public class Program
{
static void Main()
{
int a = 7;
@lats
lats / claim_all_the_things.js
Last active May 15, 2025 19:16
Tampermonkey script to claim all of the items within a Bundle on Itch.io
// ==UserScript==
// @name Activate all Itch.io Bundle downloads
// @version 1
// @include https://itch.io/bundle/download/*
// @include https://*.itch.io/*
// @require https://ajax.googleapis.com/ajax/libs/jquery/3.4.1/jquery.min.js
// @grant none
// ==/UserScript==
$(document).ready(function() {
public class AsyncLazyPipeline<TSource>
{
private Func<Task<TSource>> Expression { get; }
public AsyncLazyPipeline(Func<Task<TSource>> expression)
{
Expression = expression;
}
public Task<TSource> Flatten() => Expression();
@M4C4R
M4C4R / prettify_aws_profile.user.js
Last active July 15, 2021 15:26
Prettifies the AWS navbar where the role, account, and region are located. Click Raw to install on script managers like GreaseMonkey and Tampermonkey.
// ==UserScript==
// @author Mert Acar
// @name Make AWS Profile and Region Clearer
// @version 2
// @include https://*.aws.amazon.com/*
// @icon https://aws.amazon.com/favicon.ico
// @updateURL https://gist.github.com/M4C4R/4ee2797f37f5fbb8f814afaf549e6a5b/raw/b33b6619cf693cc6315b58cd66408d2db7c8b33a/prettify_aws_profile.user.js
// ==/UserScript==
// *** START Configuration ***
@AddonDeveloper
AddonDeveloper / 320youtube.user.js
Created April 3, 2020 08:56
The 320 kbps YouTube mp3 userscript generates a 320 kbps - MP3 DOWNLOAD button on YouTube.com. Convert YouTube to mp3 and download the file to your device.
// ==UserScript==
// @name YouTube mp3 320 kbps
// @description The 320 kbps YouTube mp3 addon generates a 320 kbps - MP3 DOWNLOAD button on YouTube.com. Convert YouTube to mp3 and download the file to your device.
// @icon https://www.320youtube.com/userscript/icon.png
//
// @author Addon Developer
// @namespace https://www.320youtube.com/
// @downloadURL https://www.320youtube.com/userscript/320youtube.user.js
//
// @license GPL-3.0-or-later
using System;
using System.Collections.Generic;
using System.Linq;
using System.Xml.Linq;
using System.Text;
using System.Threading.Tasks;
namespace GBVideoTimeCalc
{
class Program
// To view the default settings, hold "alt" while clicking on the "Settings" button.
// For documentation on these settings, see: https://aka.ms/terminal-documentation
{
"$schema": "https://aka.ms/terminal-profiles-schema",
//"defaultProfile": "{61c54bbd-c2c6-5271-96e7-009a87ff44bf}",
// "defaultProfile": "{2c4de342-38b7-51cf-b940-2309a097f518}",
"defaultProfile": "{7f586916-8357-53d4-bb2b-ca96f639898a}",
"profiles": [
{
"guid": "{7f586916-8357-53d4-bb2b-ca96f639898a}",
@lucasloss
lucasloss / StreamReaderExtensions.cs
Created December 19, 2019 22:19
System.IO.StreamReader extension methods.
using System;
using System.IO;
namespace ExtensionMethods
{
/// <summary>
/// <see cref="StreamReader"/> extension methods.
/// </summary>
public static class StreamReaderExtensions
{