Skip to content

Instantly share code, notes, and snippets.

View KyleMit's full-sized avatar

Kyle Mitofsky KyleMit

View GitHub Profile
@ericdouglas
ericdouglas / embed-plunker.html
Created December 6, 2014 13:31
Embed Plunker
<iframe style="width: 100%; height: 600px" src="http://embed.plnkr.co/GvOO1itX8MG7zJLywSN8" frameborder="0" allowfullscren="allowfullscren"></iframe>
#!/usr/bin/env ruby
#
# Shorten a GitHub URL to a git.io URL
# v1.2.0 - Copyright (c) 2016 Ryan Sobol - The MIT License
#
# Usage: gitio URL [code]
#
# Examples:
# $ gitio https://github.com/ryansobol ryansobol
# https://git.io/ryansobol
@davidwin
davidwin / profiles.schema.json
Last active April 29, 2020 05:46
Windows Terminal profiles.json schema
{
"$id": "https://github.com/microsoft/terminal/blob/master/doc/cascadia/profiles.schema.json",
"$schema": "http://json-schema.org/draft-07/schema#",
"title": "Microsoft's Windows Terminal Settings Profile Schema'",
"definitions": {
"KeyChordSegment": {
"pattern": "^(?<modifier>(ctrl|alt|shift)(?:\\+(ctrl|alt|shift)(?<!\\2))?(?:\\+(ctrl|alt|shift)(?<!\\2|\\3))?\\+)?(?<key>[^\\s+]|backspace|tab|enter|esc|escape|space|pgup|pageup|pgdn|pagedown|end|home|left|up|right|down|insert|delete|(?<!shift.+)(?:numpad_?[0-9]|numpad_(?:period|decimal)|numpad_(?:multiply|plus|add|minus|subtract|divide)|f[1-9]|f1[0-9]|f2[0-4]|plus)$",
"type": "string",
"description": "The string should fit the format \"[ctrl+][alt+][shift+]<keyName>\", where each modifier is optional, separated by + symbols, and keyName is either one of the names listed in the table below, or any single key character. The string should be written in full lowercase.\nbackspace\tBACKSPACE key\ntab\tTAB key\nenter\tENTER key\nesc\tE
@jeremywrowe
jeremywrowe / gist:3506869
Created August 29, 2012 04:33
highcharts - show label for first and last data points in a series
plotOptions: {
line : {
dataLabels : {
enabled : true,
formatter: function() {
var first = this.series.data[0],
last = this.series.data[this.series.data.length - 1];
if ((this.point.category === first.category && this.point.y === first.y) ||
(this.point.category === last.category && this.point.y === last.y)) {
return this.point.y;
@gabrielhpugliese
gabrielhpugliese / meteor-windows-vagrant-tutorial.md
Last active April 19, 2022 14:37
Tutorial for running Meteor in Windows using Vagrant

Tutorial: Meteor in Windows using Vagrant

BEFORE YOU CONTINUE:

  • Now, Meteor runs in any Windows without any line of this tutorial. Just download the Meteor binary! Yay!!
  • mrt is no longer used with Meteor 1.0

These days some people were discussing at meteor-talk group about running Meteor at Windows and I’ve recommended them using Vagrant. It’s a very developer-friendly piece of software that creates a virtual machine (VM) which let you run any operating system wanted and connect to it without big efforts of configuration (just make the initial installation and you have it working).

Many packages (I've tested) for running Meteor+Vagrant fails because Meteor writes its mongodb file and also other files inside local build folder into a shared folder between the Windows host and the Linux guest, and it simply does not work. So I've put my brain to work and found a solution: do symlinks inside the VM (but do not use ln. Use mount so git can follow it). It’s covered on

@mariusschulz
mariusschulz / HtmlHelperExtensions.cs
Last active November 15, 2022 21:54
Two C# extension methods for inlining script and style bundles into the HTML response using ASP.NET MVC and the System.Web.Optimization framework.
using System.Linq;
using System.Web;
using System.Web.Mvc;
using System.Web.Optimization;
public static class HtmlHelperExtensions
{
public static IHtmlString InlineScripts(this HtmlHelper htmlHelper, string bundleVirtualPath)
{
return htmlHelper.InlineBundle(bundleVirtualPath, htmlTagName: "script");
@KyleMit
KyleMit / cloudSettings
Last active November 26, 2022 21:24
Visual Studio Code Settings Sync Gist
{"lastUpload":"2021-04-12T13:23:41.875Z","extensionVersion":"v3.4.3"}
@bertobox
bertobox / list-styles-for-markdown.css
Created August 28, 2012 20:31
Easy list style types for Markdown
.lower_roman+ol, .lower_roman+ul {list-style-type: lower-roman;}
.upper_roman+ol, .upper_roman+ul {list-style-type: upper-roman;}
.lower_alpha+ol, .lower_alpha+ul {list-style-type: lower-alpha;}
.upper_alpha+ol, .upper_alpha+ul {list-style-type: upper-alpha;}
.lower_greek+ol, .lower_greek+ul {list-style-type: lower-greek;}
.lower_latin+ol, .lower_latin+ul {list-style-type: lower-latin;}
.upper_latin+ol, .upper_latin+ul {list-style-type: upper-latin;}
.none+ol, .none+ul {list-style-type:none;}
.disc+ol, .disc+ul {list-style-type:disc;}
.circle+ol, .circle+ul {list-style-type:circle;}
@jkrems
jkrems / index.md
Last active November 3, 2023 14:34
JavaScript: Classic Scripts vs. Modules vs. CommonJS

JavaScript File Format Differences

There's the pervarsive notion that all JS is created equal and that there's only minor and easily detectable differences between the various file formats used to author JavaScript. This is correct, from a certain point of view.

A certain point of view?

For many people writing JavaScript that gets passed into build tools,

@phuysmans
phuysmans / gist:4f67a7fa1b0c6809a86f014694ac6c3a
Created January 8, 2018 09:29
docker compose health check example
version: '2.1'
services:
php:
tty: true
build:
context: .
dockerfile: tests/Docker/Dockerfile-PHP
args:
version: cli
volumes: