Skip to content

Instantly share code, notes, and snippets.

View austegard's full-sized avatar
♻️

Oskar Austegard - old account austegard

♻️
View GitHub Profile
@austegard
austegard / tc.htm
Created July 6, 2009 14:58
Twitter Conversations
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Twitter Conversations</title>
<!-- Include jQuery -->
<script type="text/javascript">
document.write(unescape("%3Cscript src='" + document.location.protocol + "//ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js' type='text/javascript'%3E%3C/script%3E"));
document.write(unescape("%3Cscript src='" + document.location.protocol + "//ajax.googleapis.com/ajax/libs/jqueryui/1/jquery-ui.min.js' type='text/javascript'%3E%3C/script%3E"));
</script>
<!--Get the base theme firectly from the SVN trunk (cheating, I know)-->
using System;
using System.Collections.Specialized;
using System.Web;
using System.Web.Mvc;
using System.Web.Routing;
using Moq;
namespace Mvc.Web.Tests
{
public static class MvcMockHelpers
@austegard
austegard / TagBuilderExtensions.cs
Created July 31, 2009 16:12
Extensions to the TagBuilder class
using System.Web.Routing;
using System.Web.Mvc;
namespace MvcExtensions
{
/// <summary>
/// TagBuilder Extension Methods meant to streamline its use.
/// </summary>
public static class TagBuilderExtensions
{
@austegard
austegard / T4MVC.tt
Created August 28, 2009 18:12
T4MVC.tt version 2.4.01 + modifications to comply with StyleCop and CLS
<#
/*
T4MVC Version 2.4.01 + AIS Modifications
AIS Modifications are to fix StyleCop and CLSCompliant-related issues:
* Marking the file with an // <auto-generated /> comment
* Changing the region to include the term 'Generated Code'
* Marking all public members that start with _ as CLSCompliant(false)
* Marking all members that reference said members as CLSCompliant(false)
Full details at http://mo.notono.us/2009/08/making-t4mvc-comply-with-stylecop.html
@austegard
austegard / rx.js
Created November 8, 2010 15:51
Latest Reactive Extensions for JavaScript (as of 11/08/2010)
// Copyright (c) Microsoft Corporation. All rights reserved.
// This code is licensed by Microsoft Corporation under the terms
// of the MICROSOFT REACTIVE EXTENSIONS FOR JAVASCRIPT AND .NET LIBRARIES License.
// See http://go.microsoft.com/fwlink/?LinkId=186234.
(function(){var a;var b;var c=this;var d="Index out of range";if(typeof ProvideCustomRxRootObject =="undefined")b=c.Rx={}; else b=ProvideCustomRxRootObject();var e=function(){};var f=function(){return new Date().getTime();};var g=function(r0,s0){return r0===s0;};var h=function(r0){return r0;};var i=function(r0){return {Dispose:r0};};var j={Dispose:e};b.Disposable={Create:i,Empty:j};var k=b.BooleanDisposable=function(){var r0=false;this.GetIsDisposed=function(){return r0;};this.Dispose=function(){r0=true;};};var l=function(r0){var s0=false;r0.a++;this.Dispose=function(){var t0=false;if(!r0.b){if(!this.c){this.c=true;r0.a--;if(r0.a==0&&r0.d){r0.b=true;t0=true;}}}if(t0)r0.e.Dispose();};};var m=b.RefCountDisposable=function(r0){this.d=false;this.b=fals
@austegard
austegard / rxjQuery.js
Created November 8, 2010 15:54
Latest rxJquery as of 11/08/2010
// Copyright (c) Microsoft Corporation. All rights reserved.
// This code is licensed by Microsoft Corporation under the terms
// of the MICROSOFT REACTIVE EXTENSIONS FOR JAVASCRIPT AND .NET LIBRARIES License.
// See http://go.microsoft.com/fwlink/?LinkId=186234.
(function()
{
var _jQuery = jQuery;
var proto = _jQuery.fn;
var global = this;
@austegard
austegard / AmazonPrime1080
Last active August 29, 2015 14:01
Amazon Prime Video 1080px Height
The following simple bookmarklet will resize the Amazon Prime video player to 1080px, suitable for displaying on a TV, e.g. via ChromeCast.
javascript:document.getElementById('aiv-main-content').setAttribute('style', 'height:1080px');document.getElementById('player_container_wrapper').setAttribute('style','height: 1080px; opacity: 1; display: block; overflow: visible')
@austegard
austegard / Interview
Created August 17, 2022 14:59
GPT-3 Conversations
Settings:
temperature=0.5,
max_tokens=800,
top_p=1,
frequency_penalty=0.2,
presence_penalty=0.3,
stop=["?"]
Hello GPT-3 text-davinci-002 -- what a mouthful, can I call you Leo for short? I am Oskar, your human interviewer.