Skip to content

Instantly share code, notes, and snippets.

View KDawg's full-sized avatar

K KDawg

  • United States
View GitHub Profile
@KDawg
KDawg / smart-brevity-of-article.md
Created July 13, 2026 15:13
Smart Brevity Prompt (with GPT LLM)

GOAL

Analyze the article at this URL:

[PASTE URL]

Based on the provided article text, generate an internal engineering update that summarizes the key insights and practical implications for our team.

The goal is not simply to summarize the article. The goal is to help engineers, application architects, software developers, UX designers, and product managers quickly understand:

<section>
<img src="/assets/images/LogoMark.svg" class="logo-mark__article-end-mark"
alt="Ending logo Mark for this article"/>
</section>
.logo-mark__article-end-mark {
display: block;
margin: 0 auto;
}
@media screen and (max-width: 650px) {
.logo-mark__article-end-mark {
transform: scale(0.75, 0.75);
}
}
@KDawg
KDawg / TuplesExample.swift
Created August 30, 2019 16:22
This is an example of the Tuple type in Swift programming language
// This is an example of the Tuple type in Swift programming language
// I use this type of data to easily return multiple values from a function call
// SEE: https://docs.swift.org/swift-book/LanguageGuide/TheBasics.html#ID329
let t = (200, "OK", "HTTP 200 is a successful return code. The request has succeeded.")
print(t) // shows the entire tuple
print(t.0) // shows 200
print(t.1) // shows "OK"
print(t.2) // shows the longer message
@KDawg
KDawg / gist:10537524
Created April 12, 2014 14:10
Debug Unity3D OnGui Label Text With Background
// display a background texture banner
GUI.DrawTexture(new Rect(-30.0f, 384.0f, m_topScoreBanner.width, m_topScoreBanner.height), m_topScoreBanner);
Vector2 pivotPoint = new Vector2(Screen.width / 2, Screen.height / 2);
GUIStyle scoreStyle = new GUIStyle();
// DEBUG: create a background texture coloring the entire label background
Texture2D debugTex = new Texture2D(1,1);
debugTex.SetPixel(0,0,Color.grey);
debugTex.Apply();
@KDawg
KDawg / FB_JS_SDK_CHECKIN_RESPONSE.js
Created January 29, 2013 21:46
Facebook JS SDK /me/checkins service response
// Simply logging into Facebook via their JavaScript SDK:
FB.login(function(response) {
// assuming a valid response executing this FQL:
FB.api('/me/checkins', function(response) {
console.log('me', response);
});
}, {scope: 'email,user_status,user_checkins,user_likes,user_interests,user_location,friends_location'});
// these are the contents of service response as a JS object
@KDawg
KDawg / FB_JS_SDK_LIKES_RESPONSE.js
Last active December 11, 2015 21:59
Facebook JS SDK /me/likes service response
// Simply logging into Facebook via their JavaScript SDK:
FB.login(function(response) {
// assuming a valid response executing this FQL:
FB.api('/me/likes', function(response) {
console.log('me', response);
});
}, {scope: 'email,user_status,user_checkins,user_likes,user_interests,user_location,friends_location'});
// these are the contents of service response as a JS object
@KDawg
KDawg / FB_JS_SDK_FRIEND_RESPONSE.js
Last active December 11, 2015 21:58
Facebook JS SDK /me/friend service response
// Simply logging into Facebook via their JavaScript SDK:
FB.login(function(response) {
// assuming a valid response executing this FQL:
FB.api('/me/friends', function(response) {
console.log('me', response);
});
}, {scope: 'email,user_status,user_checkins,user_likes,user_interests,user_location,friends_location'});
// these are the contents of service response as a JS object
@KDawg
KDawg / FB_JS_SDK_ME_RESPONSE.js
Created January 28, 2013 23:03
Facebook JS SDK /me service response
// Simply logging into Facebook via their JavaScript SDK:
FB.login(function(response) {
// assuming a valid response executing this FQL:
FB.api('/me', function(response) {
console.log('me', response);
});
}, {scope: 'email,user_status,user_checkins,user_likes,user_interests,user_location,friends_location'});
// these are the contents of service response as a JS object
@KDawg
KDawg / jasmine_test_boilerplate.js
Created January 23, 2013 21:22
Skeleton poofing a new Jasmine test JS in our TC project world
require(['mediator', 'jquery', 'underscore', 'backbone', 'namespace', 'i18n!common/i18n/nls/strings',
'models/the_feature/some_model', 'views/the_feature/some_view'],
function(mediator, $, _, Backbone, app, t, TheModel, TheView) {
describe('Create Trip View', function() {
var createModel, createView;
beforeEach(function() {
createModel = new Backbone.Model();
createView = new Backbone.View({model: createModel});