Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,12 @@ jobs:
cache: 'npm'
registry-url: 'https://registry.npmjs.org'

- name: Install dependencies
run: npm ci

- name: Build theme
run: npm run build

- name: Publish to npm
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
Expand Down
14 changes: 14 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,20 @@ jobs:
fi
echo "✅ All theme files generated successfully"

- name: Verify ESM wrapper modules exist
run: |
for theme in pierre-dark pierre-light pierre-dark-vibrant pierre-light-vibrant; do
if [ ! -f "dist/${theme}.mjs" ]; then
echo "❌ dist/${theme}.mjs not generated"
exit 1
fi
done
if [ ! -f "dist/index.mjs" ]; then
echo "❌ dist/index.mjs not generated"
exit 1
fi
echo "✅ All ESM wrapper modules generated successfully"

- name: Check file sizes
run: |
light_size=$(wc -c < themes/pierre-light.json)
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
.DS_Store
node_modules/
build
dist
*.vsix
1 change: 1 addition & 0 deletions .vscodeignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,4 @@
/package-lock.json
/src/
/build/
/dist/
28 changes: 26 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,30 @@ OPEN POSITIONS: [Systems Engineer](https://pierre.computer/careers/systems-engin

~~~

Overview:
- Light and dark themes for Visual Studio Code, Cursor, Zed, and Shiki.
Overview:
- Light and dark themes for Visual Studio Code, Cursor, Zed, and Shiki.
- Built for [Diffs.com](https://diffs.com)

~~~

Usage:

VS Code / Cursor:
1. Install "Pierre Theme" from the Extensions marketplace
2. Cmd+Shift+P > "Color Theme" > select Pierre Light or Pierre Dark

Shiki / npm:
npm install @pierre/theme

import pierreDark from '@pierre/theme/pierre-dark'
import pierreLight from '@pierre/theme/pierre-light'

Available themes:
- @pierre/theme/pierre-dark
- @pierre/theme/pierre-light
- @pierre/theme/pierre-dark-vibrant (Display P3)
- @pierre/theme/pierre-light-vibrant (Display P3)

Zed:
Install "Pierre" from the Zed extension registry
```
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

14 changes: 12 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "@pierre/theme",
"displayName": "Pierre Theme",
"description": "Pierre theme for Shiki, VS Code, and more",
"version": "0.0.24",
"version": "0.0.25",
"publisher": "pierrecomputer",
"icon": "icon.png",
"galleryBanner": {
Expand Down Expand Up @@ -47,14 +47,24 @@
"build": "ts-node src/build.ts",
"test": "npm run build && ts-node src/test.ts",
"start": "nodemon --watch src --ext ts --exec npm run build",
"package": "ts-node src/package-vsix.ts"
"package": "ts-node src/package-vsix.ts",
"prepublishOnly": "npm run build"
},
"devDependencies": {
"@vscode/vsce": "^3.2.2",
"nodemon": "^3.1.11",
"ts-node": "^10.9.2",
"typescript": "^5.9.3"
},
"sideEffects": false,
"exports": {
".": "./dist/index.mjs",
"./pierre-dark": "./dist/pierre-dark.mjs",
"./pierre-light": "./dist/pierre-light.mjs",
"./pierre-dark-vibrant": "./dist/pierre-dark-vibrant.mjs",
"./pierre-light-vibrant": "./dist/pierre-light-vibrant.mjs",
"./themes/*": "./themes/*"
},
"publishConfig": {
"access": "public"
}
Expand Down
21 changes: 21 additions & 0 deletions src/build.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,3 +37,24 @@ const zedTheme = makeZedThemeFamily("Pierre", "pierrecomputer", [

writeFileSync("zed/themes/pierre.json", JSON.stringify(zedTheme, null, 2), "utf8");
console.log("Wrote zed/themes/pierre.json");

// ============================================
// ESM wrapper modules (for npm / Shiki consumers)
// ============================================
mkdirSync("dist", { recursive: true });

const themeNames: string[] = [];

for (const { file, theme } of vscodeThemes) {
const name = file.replace("themes/", "").replace(".json", "");
themeNames.push(name);
const json = JSON.stringify(theme);
const escaped = json.replace(/\\/g, "\\\\").replace(/'/g, "\\'");
const mjs = `export default Object.freeze(JSON.parse('${escaped}'))\n`;
writeFileSync(`dist/${name}.mjs`, mjs, "utf8");
console.log("Wrote", `dist/${name}.mjs`);
}

const indexMjs = `export const themeNames = ${JSON.stringify(themeNames)}\n`;
writeFileSync("dist/index.mjs", indexMjs, "utf8");
console.log("Wrote dist/index.mjs");
2 changes: 1 addition & 1 deletion zed/extension.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
id = "pierre-theme"
name = "Pierre"
description = "A warm, orange-accented color theme with light and dark variants"
version = "0.0.24"
version = "0.0.25"
schema_version = 1
authors = ["pierrecomputer"]
repository = "https://github.com/pierrecomputer/pierre-theme"
Loading