Skip to content

Commit 96d2a11

Browse files
committed
feat: VS Code Discord Rich Presence
Python tool for advanced Discord RPC integration with VS Code.
0 parents  commit 96d2a11

25 files changed

+3509
-0
lines changed

.github/CODEOWNERS

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
* @ImpulseB23

.github/dependabot.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
version: 2
2+
updates:
3+
- package-ecosystem: pip
4+
directory: /
5+
target-branch: dev
6+
schedule:
7+
interval: weekly
8+
open-pull-requests-limit: 3
9+
- package-ecosystem: github-actions
10+
directory: /
11+
target-branch: dev
12+
schedule:
13+
interval: monthly
14+
open-pull-requests-limit: 3

.github/pull_request_template.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
## Summary
2+
## Changes
3+
-
4+
## Test Plan
5+
- [ ] Tested locally
6+
## Notes

.github/workflows/ci.yml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
name: CI
2+
on:
3+
pull_request:
4+
branches: [main, dev]
5+
push:
6+
branches: [main, dev]
7+
concurrency:
8+
group: ci-${{ github.ref }}
9+
cancel-in-progress: true
10+
jobs:
11+
lint:
12+
name: Lint
13+
runs-on: ubuntu-latest
14+
steps:
15+
- uses: actions/checkout@0c366fd6a839edf440554fa01a7085ccba70ac98 # v4
16+
- uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6
17+
with:
18+
python-version: "3.12"
19+
- run: pip install ruff
20+
- run: ruff check .
21+
- run: ruff format --check .

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
.venv/

CONTRIBUTING.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# Contributing to VS Code RPC
2+
## Branch Workflow
3+
`feature/*``dev``main`. Always branch from `dev`.
4+
## Commit Messages
5+
Use conventional commits: `feat:`, `fix:`, `refactor:`, `chore:`

LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2026 FROSTCRYPT LLC
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

SECURITY.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
# Security Policy
2+
## Reporting a Vulnerability
3+
Email **security@frostcrypt.com**. Do NOT open a public issue.
4+
We will acknowledge receipt within 48 hours.

config.toml

Lines changed: 164 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,164 @@
1+
# ──────────────────────────────────────────────────────────────
2+
# VS Code Discord RPC — Configuration
3+
# ──────────────────────────────────────────────────────────────
4+
# Template variables you can use in any string field:
5+
# {workspace} — project/folder name
6+
# {filename} — current file name (e.g. "model.py")
7+
# {filepath} — relative file path
8+
# {language} — detected language (e.g. "Python")
9+
# {language_icon} — icon key for the language (must match Discord asset)
10+
# {activity} — auto-detected activity label
11+
# {branch} — current git branch
12+
# {problems} — number of workspace problems (if available)
13+
# {line_count} — lines in the current file
14+
# {file_size} — human-readable file size
15+
# {elapsed} — time since presence started
16+
# ──────────────────────────────────────────────────────────────
17+
18+
[discord]
19+
client_id = "1469848428467982408"
20+
21+
[presence]
22+
# What shows on your Discord profile
23+
details = "{activity}"
24+
state = "{filename} | {workspace}"
25+
large_image = "{language_icon}"
26+
large_text = "{language}"
27+
small_image = "vscode"
28+
small_text = "Visual Studio Code"
29+
show_elapsed = true
30+
31+
# Override: set a static presence (ignores templates above)
32+
# Uncomment to use:
33+
# [presence.override]
34+
# details = "Building something cool"
35+
# state = "In the zone"
36+
37+
[vscode]
38+
# "auto" = follow the most recently focused VS Code window
39+
# Or set a workspace path to lock onto a specific instance:
40+
# instance = "/home/user/projects/my-project"
41+
instance = "auto"
42+
43+
# How often to poll for updates (seconds)
44+
poll_interval = 5
45+
46+
[detection]
47+
# Toggle individual detectors on/off
48+
ml_training = true
49+
gpu_monitoring = true
50+
debugging = true
51+
git_activity = true
52+
docker = true
53+
build_tasks = true
54+
testing = true
55+
56+
# GPU utilization threshold (%) to flag as "training"
57+
gpu_threshold = 30
58+
59+
# Extra process keywords that signal ML training
60+
ml_process_keywords = [
61+
"train", "fit", "epoch", "finetune", "fine_tune",
62+
"accelerate", "deepspeed", "torchrun",
63+
]
64+
65+
# Python imports that signal ML work
66+
ml_module_keywords = [
67+
"torch", "tensorflow", "keras", "lightning",
68+
"transformers", "sklearn", "jax", "flax",
69+
"diffusers", "accelerate", "wandb", "mlflow",
70+
]
71+
72+
# Priority order (lower = higher priority, checked first)
73+
[detection.priorities]
74+
debugging = 1
75+
ml_training = 2
76+
testing = 3
77+
build_tasks = 4
78+
docker = 5
79+
git_activity = 6
80+
81+
# ── Discord activity type mapping ─────────────────────────
82+
# 0 = Playing, 3 = Watching, 5 = Competing
83+
[presence.activity_types]
84+
editing = 0
85+
deep_coding = 0
86+
writing_model_code = 0
87+
debugging = 0
88+
training_model = 0
89+
building = 0
90+
reviewing_code = 3
91+
exploring_codebase = 3
92+
writing_docs = 3
93+
running_tests = 5
94+
writing_tests = 5
95+
configuring = 0
96+
idle = 0
97+
default = 0
98+
99+
# ── Dynamic small icon per activity ──────────────────────
100+
[presence.activity_icons]
101+
training_model = "brain"
102+
ml_training = "brain"
103+
debugging = "bug"
104+
testing = "flask"
105+
running_tests = "flask"
106+
writing_tests = "flask"
107+
building = "gear"
108+
docker = "docker"
109+
editing = "vscode"
110+
deep_coding = "vscode"
111+
reviewing_code = "vscode"
112+
exploring_codebase = "vscode"
113+
writing_docs = "vscode"
114+
configuring = "gear"
115+
idle = "vscode"
116+
default = "vscode"
117+
118+
[activity_labels]
119+
# Customize the text shown for each detected activity
120+
ml_training = "Training a neural network"
121+
debugging = "Debugging"
122+
testing = "Running tests"
123+
building = "Building project"
124+
git_merge = "Resolving merge conflicts"
125+
git_rebase = "Rebasing"
126+
git_general = "Working with Git"
127+
docker = "Working with Docker"
128+
editing = "Editing"
129+
reading = "Reading"
130+
idle = "Idling in VS Code"
131+
132+
[language_icons]
133+
# Map language names to Discord Rich Presence asset keys.
134+
# Upload matching images at: discord.com/developers → your app → Rich Presence → Art Assets
135+
# The key here must match the asset name you uploaded.
136+
python = "python"
137+
javascript = "javascript"
138+
typescript = "typescript"
139+
rust = "rust"
140+
go = "go"
141+
java = "java"
142+
c = "c"
143+
cpp = "cpp"
144+
csharp = "csharp"
145+
html = "html"
146+
css = "css"
147+
scss = "scss"
148+
json = "json"
149+
yaml = "yaml"
150+
toml = "toml"
151+
markdown = "markdown"
152+
shell = "shell"
153+
dockerfile = "docker"
154+
sql = "sql"
155+
lua = "lua"
156+
ruby = "ruby"
157+
php = "php"
158+
swift = "swift"
159+
kotlin = "kotlin"
160+
dart = "dart"
161+
vue = "vue"
162+
svelte = "svelte"
163+
react = "react"
164+
default = "code"

data/.gitkeep

Whitespace-only changes.

0 commit comments

Comments
 (0)