Skip to content

Commit

Permalink
Initial commit: Windsurf Cascade Step Tracker Extension
Browse files Browse the repository at this point in the history
  • Loading branch information
SuBL1MMe committed Dec 5, 2024
0 parents commit c5712cb
Show file tree
Hide file tree
Showing 10 changed files with 946 additions and 0 deletions.
25 changes: 25 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Dependencies
node_modules/

# Build outputs
out/
dist/
*.vsix

# Logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*

# Editor directories and files
.vscode/*
!.vscode/settings.json
!.vscode/tasks.json
!.vscode/launch.json
!.vscode/extensions.json
*.code-workspace

# OS specific files
.DS_Store
Thumbs.db
21 changes: 21 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2024 Windsurf AI

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
162 changes: 162 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,162 @@
# Windsurf Cascade Monthly Step Tracker

A Windsurf IDE extension that helps you track and manage your Windsurf AI Cascade steps across different projects. Keep track of your monthly step usage and ensure you stay within your limits.

## Features

- 📊 Track total steps used across all projects
- 🎯 Monitor monthly step limits
- 📝 Project-specific step tracking
- 🔄 Reset count functionality
- 📅 Automatic monthly usage tracking
- 💾 Persistent storage of step data
- 🖥️ Convenient sidebar view

## Installation

1. Download the `.vsix` file from the releases page
2. Open VS Code
3. Press `Ctrl+Shift+P` (Windows/Linux) or `Cmd+Shift+P` (Mac)
4. Type "Install from VSIX" and select it
5. Navigate to the downloaded `.vsix` file and install

## Usage

### Accessing the Step Tracker

1. Look for the Step Tracker icon in the VS Code activity bar (side bar)
2. Click it to open the Step Tracker panel

### Adding Steps

1. The current project name will be automatically detected from your workspace
2. Enter the number of steps in the input field
3. Click "Add Steps" to record them

### Viewing Statistics

- Total steps used this month
- Monthly step limit
- Per-project step usage
- Last update timestamp

### Resetting Count

- Use the "Reset Count" button to manually reset your step count
- Counts automatically reset at the beginning of each month

### Managing Projects

- Steps are tracked per project
- Project information is automatically detected from your workspace
- Step history is maintained for each project separately

### Configuring Monthly Step Limit

You can change your monthly step limit in two ways:

1. **Through Windsurf Settings**
- Open Windsurf Settings
- Search for "windsurf-step-tracker"
- Look for the "Monthly Limit" setting
- Enter your desired step limit (default is 1000)

2. **Directly in step-tracker.json**
- Navigate to `~/.windsurf/step-tracker.json`
- Find the `monthly_limit` field
- Update the value to your desired limit
- Save the file

### Tracking Steps with Cascade AI

Important: You need to explicitly ask Cascade to track steps - it does not happen automatically!

The step tracking data is stored in:
```
~/.windsurf/step-tracker.json
```

Here's how to track your steps:

1. **Request Step Tracking**
- At the beginning of your conversation, tell Cascade: "Please track steps for this conversation"
- Or at any point during/after the conversation: "Please add X steps to my tracker"
- Make sure to request tracking for each conversation where you want to count steps

2. **View Current Stats**
- Check the Step Tracker panel in the sidebar
- Look directly at the `step-tracker.json` file in your home directory
- Ask Cascade: "How many steps have I used so far?"

3. **Best Practices**
- Always request step tracking at the start of important conversations
- Monitor your usage regularly through the Step Tracker panel
- Review the `step-tracker.json` file if you need detailed history
- Keep track of your monthly limits to avoid interruptions

Remember: If you don't explicitly ask Cascade to track steps, they won't be recorded in your step count!

## Data Storage

The extension stores all step tracking data in the `.windsurf` directory in your home folder. The data persists between Windsurf sessions and is shared across different Windsurf windows.

## Requirements

- Windsurf IDE
- Active Windsurf AI Cascade subscription

## Contributing

Feel free to submit issues and enhancement requests through the GitHub repository.

## License

[MIT License](LICENSE)

## Release Notes

### 0.1.0

Initial release of Windsurf Cascade Monthly Step Tracker:
- Basic step tracking functionality
- Project-specific tracking
- Monthly limits
- Persistent storage
- User-friendly interface

## Building from Source

If you want to build the extension from source:

1. **Clone the Repository**
```bash
git clone https://github.com/SuBL1MMe/windsurf-cascade-step-tracker.git
cd windsurf-cascade-step-tracker
```

2. **Install Dependencies**
```bash
npm install
npm install -g @vscode/vsce # Install vsce globally if you haven't already
```

3. **Compile TypeScript**
```bash
npm run compile
# or for development with watch mode:
npm run watch
```

4. **Package the Extension**
```bash
vsce package
```
This will create a `.vsix` file in the root directory.

5. **Install the Extension**
- Open Windsurf IDE
- Press `Ctrl+Shift+P` (Windows/Linux) or `Cmd+Shift+P` (Mac)
- Type "Install from VSIX" and select it
- Navigate to the generated `.vsix` file and install

Note: Make sure you have Node.js and npm installed on your system before starting.
48 changes: 48 additions & 0 deletions package-lock.json

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

81 changes: 81 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
{
"name": "windsurf-step-tracker",
"displayName": "Windsurf Cascade Monthly Step Tracker",
"description": "Track Windsurf AI Cascade steps across projects",
"version": "0.1.0",
"publisher": "SuBL1MMe",
"repository": {
"type": "git",
"url": "https://github.com/SuBL1MMe/windsurf-cascade-step-tracker.git"
},
"license": "MIT",
"engines": {
"vscode": "^1.60.0"
},
"categories": [
"Other"
],
"activationEvents": [
"onView:stepTrackerView",
"onCommand:windsurf-step-tracker.showSteps",
"onCommand:windsurf-step-tracker.addSteps",
"onCommand:windsurf-step-tracker.resetCount"
],
"main": "./out/extension.js",
"contributes": {
"commands": [
{
"command": "windsurf-step-tracker.showSteps",
"title": "Show Step Count"
},
{
"command": "windsurf-step-tracker.addSteps",
"title": "Add Steps"
},
{
"command": "windsurf-step-tracker.resetCount",
"title": "Reset Step Count"
}
],
"viewsContainers": {
"activitybar": [
{
"id": "step-tracker",
"title": "Step Tracker",
"icon": "resources/step-icon.svg"
}
]
},
"views": {
"step-tracker": [
{
"type": "webview",
"id": "stepTrackerView",
"name": "Step Count"
}
]
},
"configuration": {
"title": "Windsurf Cascade Monthly Step Tracker",
"properties": {
"windsurf-step-tracker.monthlyLimit": {
"type": "number",
"default": 1000,
"description": "Monthly cascade step limit for Windsurf AI"
}
}
}
},
"scripts": {
"vscode:prepublish": "npm run compile",
"compile": "tsc -p ./",
"watch": "tsc -watch -p ./",
"pretest": "npm run compile",
"test": "node ./out/test/runTest.js"
},
"devDependencies": {
"@types/vscode": "^1.60.0",
"@types/node": "^14.17.0",
"typescript": "^4.3.5"
}
}
10 changes: 10 additions & 0 deletions resources/step-icon.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Empty file added src/README.md
Empty file.
Loading

0 comments on commit c5712cb

Please sign in to comment.