Skip to content

Instantly share code, notes, and snippets.

@titancode
titancode / gist:7373f0b63851787e6cb26f8fd594d017
Created March 7, 2026 19:54
Alfred workflow AppleScript for creating or resuming a Yatoro screen session in Ghostty
-- Create or resume a GNU screen session named "music" in Ghostty.
-- If the session does not exist, launch Yatoro and run a list of startup commands.
-- Designed for use in an Alfred workflow.
-- It's mostly created by ChatGPT
on run argv
if (count of argv) is 0 then return
set actionName to item 1 of argv
@titancode
titancode / gist:17b76bf7d1484a12dd716732d6d8f4e8
Last active March 7, 2026 19:50
Alfred workflow AppleScript for creating or resuming a Yatoro screen session in Ghostty
-- Create or resume a GNU screen session named "music" in Ghostty.
-- If the session does not exist, launch Yatoro and run a list of startup commands.
-- Designed for use in an Alfred workflow.
-- It's mostly created by ChatGPT
on run argv
if (count of argv) is 0 then return
set actionName to item 1 of argv
@titancode
titancode / bret_victor-reading_list.md
Created November 30, 2022 08:47 — forked from nickloewen/bret_victor-reading_list.md
Bret Victor’s Reading List

This is a plain-text version of Bret Victor’s reading list. It was requested by hf on Hacker News.


Highly recommended things!

This is my five-star list. These are my favorite things in all the world.

A few of these works have had an extraordinary effect on my life or way of thinking. They get a sixth star. ★

@titancode
titancode / gist:1417651
Last active September 28, 2015 09:18
An AppleScript for automatically switching your iTunes Store accounts between countries. (for people who use Chinese ver. of Mac OS X 10.7)
tell application "System Events"
tell process "iTunes"
set frontmost to true
try
click menu item "登出" of menu "帳號" of menu bar item "帳號" of menu bar 1
end try
delay 1
click menu item "登入⋯" of menu "帳號" of menu bar item "帳號e" of menu bar 1
delay 1
keystroke "帳號的第一個字母"
@titancode
titancode / gist:1086104
Created July 16, 2011 07:28
An AppleScript for automatically switching your iTunes Store accounts between countries.
tell application "System Events"
tell process "iTunes"
set frontmost to true
try
click menu item "Sign Out" of menu "Store" of menu bar item "Store" of menu bar 1
end try
delay 1
click menu item "Sign In" of menu "Store" of menu bar item "Store" of menu bar 1
delay 1
keystroke return