Skip to content

xscriptor/xcode

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Xcode Xscriptor

Convert ANSI terminal color palettes (16 colors per palette, 12 palettes) to .xccolortheme files for Xcode.

License: MIT Xcode Python Themes

Content


Overview

This generator reads ANSI terminal palettes (16 colors each, 12 palettes) defined in colors.md and produces Xcode .xccolortheme files. Each palette maps to 24 Xcode syntax tokens (keywords, strings, comments, types, etc.) so that the editor's syntax highlighting matches the terminal color scheme.

Canonical themes live in themes/. When the source palette changes, run the generator to rebuild them into labs/dist/.


Themes

Theme Background Type
X#050505dark
Madrid#fafafalight
Lahabana#19191adark
Miami#000000dark
Paris#1a0a30dark
Tokio#1c1c1ddark
Oslo#3f4451dark
Helsinki#f8fafelight
Berlin#000000dark (monochrome)
London#fffffflight (monochrome)
Praha#1a1a1adark
Bogota#200b0adark

Usage

cd labs
python3 generate_themes.py

All .xccolortheme files are written to labs/dist/. Once tested, promote them to themes/ if desired.

Programmatic API

from labs.generate_themes import make_theme, THEMES, SYNTAX_MAP

theme = THEMES["Praha"]
colors = make_theme("Praha", theme)


Installation

Local

./install.sh              # install all themes
./install.sh Praha        # install a single theme

Remote (from GitHub)

REPO="xscriptor/xcode" bash <(curl -fsSL https://raw.githubusercontent.com/xscriptor/xcode/main/install.sh)

Install a single theme remotely:

REPO="xscriptor/xcode" bash <(curl -fsSL https://raw.githubusercontent.com/xscriptor/xcode/main/install.sh) -s Praha

Uninstall

./install.sh -u                                      # local uninstall
REPO="xscriptor/xcode" bash <(curl -fsSL ...) -s -- -u   # remote uninstall

This removes any theme file matching the known theme names from ~/Library/Developer/Xcode/UserData/FontAndColorThemes/.

After installation, restart Xcode and select the theme from Xcode > Preferences > Themes.



X

X Web & X Github Profile & Xscriptor web

Releases

No releases published

Packages

 
 
 

Contributors