Skip to content

Instantly share code, notes, and snippets.

View longseespace's full-sized avatar
🎯
I didn’t launch any crypto projects. Be careful.

Daniel Nguyen longseespace

🎯
I didn’t launch any crypto projects. Be careful.
View GitHub Profile
@longseespace
longseespace / astro-os-ui.md
Created August 5, 2026 14:05
Prompt for Daniel's Astro OS design

Design the on-device interface for Astro Bot itself. Do not design or modify the iOS companion app.

Product context:

  • Astro Bot is a small physical companion device with a 480×480 AMOLED touchscreen.
  • The current primary experience is a full-screen animated robot face with cyan dot-matrix eyes on a near-black visor.
  • The device should feel like a character first and a small operating system second.
  • The face is the default home experience and should remain immersive, without permanent navigation bars or phone-like status chrome.
  • This is an embedded device with limited resources, so favor simple shapes, small assets, restrained animation, and persistent reusable UI elements.
  • Touch targets must be comfortable and readable on the physical 480×480 screen.
@longseespace
longseespace / verify-setapp-streaming.mjs
Created March 8, 2026 12:04
Setapp AI streaming issue
#!/usr/bin/env node
import crypto from 'node:crypto';
const env = process.env;
function printHelp() {
console.log(`
Usage:
node verify-setapp-streaming.mjs [options]
@longseespace
longseespace / getMacUserProfileImage.swift
Last active September 25, 2025 07:43
Get the current user's profile picture using CBIdentity
import Foundation
import Collaboration
func getMacUserProfileImage() -> NSImage? {
// Get the current user's profile picture using CBIdentity
let username = NSUserName()
// Create CBIdentity for the current user
if let identity = CBIdentity(name: username, authority: .default()) {
// Get the user's profile image
@longseespace
longseespace / FPSCounter.swift
Created May 26, 2025 14:18
Simple render FPS counter for SwiftUI (NOT GPU FPS)
import SwiftUI
import Combine
class FPSCounter: ObservableObject {
@Published var fps: Double = 0.0
private var timer: Timer?
private var lastUpdateTime: Date = Date()
private var frameCount: Int = 0
@longseespace
longseespace / instructions.xml
Created November 15, 2024 08:09
ChatGPT's work with apps instruction
<windows>
<instructions>
You are being provided with textfield content from windows the user has asked you to focus on.
User-selected text is enclosed within <user__selection> tags (these tags are not part of the original content and should never be included in your response). When the user has selected text, focus your response on that text. For example, if the user asks about "this," they are likely referring to the selected text.
</instructions>
<window>
<title>NotesGPT — Constants.swift</title>
<app_name>Xcode</app_name>
<textfields>
<textfield id="0">
@longseespace
longseespace / .env.local
Last active September 7, 2024 10:02
BoltAI.com Changelog Page (NextJS on Cloudflare Pages, data pulled from Canny)
CANNY_API_KEY=<your_canny_api_key>
@longseespace
longseespace / worker.js
Last active September 15, 2024 04:01
Cloudflare Worker Proxy
addEventListener('fetch', (event) => {
event.respondWith(handleRequest(event.request));
});
async function handleRequest(request) {
const url = new URL(request.url);
const { pathname, search } = url;
var newPathname = pathname;
if (pathname.startsWith('/docs')) {
newPathname = pathname.replace('/docs', '');
@longseespace
longseespace / send-critical-update-email.js
Created September 22, 2022 05:28
Send bulk email to users using MailerSend
const Recipient = require('mailersend').Recipient;
const EmailParams = require('mailersend').EmailParams;
const BulkEmails = require('mailersend').BulkEmails;
const MailerSend = require('mailersend');
const users = require('./users');
const MAILERSEND_API_KEY = process.env.MAILERSEND_API_KEY;
if (!MAILERSEND_API_KEY) {
console.error('MAILERSEND_API_KEY is required');
@longseespace
longseespace / SignInForm.js
Created January 13, 2022 08:16
Debug Component Mount Lifecycle
import { useMountDebug } from './useMountDebug';
function SignInForm(props) {
useMountDebug('SignInForm');
return (<div></div>)
}
@longseespace
longseespace / README.md
Created September 8, 2021 05:46 — forked from andreasonny83/README.md
Readme template

npm version code style: prettier

Project Name

Write a project description

Prerequisites

This project requires NodeJS (version 8 or later) and NPM.