You are browsing as a guest. Sign up (or log in) to start making projects!

madushankarajapaksha999

@madushankarajapaksha999

Joined June 5th, 2026

  • 4Devlogs
  • 2Projects
  • 0Ships
  • 0Votes
Open comments for this post

50m 57s logged

Wiring the Engine + Config Schema

I wired up the TabTracker into the actual extension entry point today. Made an extension.ts that instantiates the trackr when VS Code activates the extension, then immediately scans all already-open text documents and registers them with touchTab() so nothing gets lost if the user already has files open. I hooked into onDidChangeActiveTextEditr to call touchTab() every time the user switches tabs, and onDidCloseTextDocument to remove tabs when files close. I also set up a setInterval that fires every 60 second to call updateAllStages() so the decay actually progresses in real time without waiting for someone to interact.I also completely redid the configuration schem in package.json. Instead of the array-based thresholds I had before, I switched to individual keys : tabRot.stage1Threshold, stage2Threshold, and stage3Threshold with defaults of 60, 1440, and 10080 minutes respectively. That maps to 1 hour, 1 day, and 1 week which feels way more intuitive than the old array. I also added two boolean flags — enableDecorations and enableStatusBar — so users can toggle the UI features later without digging through code.I updated tabTracker.ts to read from the individual config key instead of the array, and kept the hot-reload listener so if someone edits their settings the thresholds update live. I peppered console.log everywhere for debugging — activation messages, tab touch events, removals, and a periodic log of how many decayed tabs exist.

0
0
14
Open comments for this post

1h 26m 18s logged

Core State Engine — tabTracker.ts

I finally started the actual VS Code extension part of Tab Rot after planning everything out. Today’s goal was just the core state engine — basically tracking when each file was last visited and making sure it survives if you close and reopen VS Code. I made a tabTracker.ts file that has a TabState interface and a TabTracker class. The interface is super strict with the decay stages locked to 0 | 1 | 2 | 3 which felt like good TypeScript practice but also kind of a pain later.The tracker uses a Map to hold everything in memory, but it loads from and saves to context.workspaceState so the data persists across restarts. I added all the main methods — touchTab() to mark something as visited right now, removeTab() when a file closes, getDecayStage() to figure out how rotten a tab is based on the time thresholds, and getDecayedTabs() to spit out everything that’s stage 1 or higher sorted by how dead it is. I also threw in restoreTab() and restoreAllTabs() for when you want to pretend you never abandoned that file.I set it up to read the decay thresholds from VS Code settings (tabRot.decayThresholds) and even made it hot-reload when you change the config without restarting the whole editor. Oh and I added a debounced save because I realized it would be stupid to write to disk every single time you switch tab

0
0
6
Open comments for this post

30m 33s logged

Planned the Tab Root Project

Today, I planned the development roadmap for my Tab Root VS Code extension. After finishing the initial project setup, I broke the project into smaller tasks and subtasks so I can develop the extenssion step by step.I created a task list covering the main parts of the project, including tab tracking, the decay system, tab activity detection, visual tab changes, restore functionality, user configuration, testing, documentation, and the final release.Breaking the project into small tasks should make it easier to track my progress and understand what I need to work on next. I also organized the tasks into diffarent phase so I can focus on building the core functionality before moving on to the UI and release.

0
0
18
Open comments for this post

43m 54s logged

Implemented Project Structure

What I worked on:Today, I started working on my first VS Code extension, called Tab Root. I initialized the project and set up Git for version control. I also created the basic file and folder structure for the extension and configured the project to use TypeScript.After setting everything up, I created my first working VS Code extension. I added a basic VS Code command and tested it successfully inside VS Code. This was my first time creating and running an extension, so getting the basic setup working was an important first step for the project.

0
0
46

Followers

Loading…