Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: GuyNachshon/cline
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: main
Choose a base ref
...
head repository: cline/cline
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: main
Choose a head ref
Able to merge. These branches can be automatically merged.
Loading
Showing with 7,202 additions and 1,679 deletions.
  1. +0 −7 .changeset/.mighty-tools-remain.md
  2. +5 −0 .changeset/breezy-items-bake.md
  3. +5 −0 .changeset/chatty-scissors-rescue.md
  4. +5 −0 .changeset/dirty-rice-film.md
  5. +5 −0 .changeset/fluffy-pants-jog.md
  6. +5 −0 .changeset/little-tomatoes-drive.md
  7. +5 −0 .changeset/mighty-pants-sort.md
  8. +5 −0 .changeset/nasty-radios-dance.md
  9. +5 −0 .changeset/tall-rivers-knock.md
  10. +1 −1 .clinerules
  11. +1 −1 .github/CODEOWNERS
  12. +32 −56 .github/scripts/overwrite_changeset_changelog.py
  13. +91 −0 .github/workflows/changeset-converter.yml
  14. +0 −117 .github/workflows/check-changeset.yml
  15. +1 −0 .gitignore
  16. +40 −0 CHANGELOG.md
  17. +30 −0 CONTRIBUTING.md
  18. +1 −1 docs/mcp/mcp-server-from-github.md
  19. +8 −0 esbuild.js
  20. +25 −23 locales/zh-tw/CODE_OF_CONDUCT.md
  21. +61 −58 locales/zh-tw/CONTRIBUTING.md
  22. +96 −70 locales/zh-tw/README.md
  23. +1,863 −155 package-lock.json
  24. +88 −9 package.json
  25. +30 −0 scripts/test-ci.js
  26. +200 −1 src/api/providers/bedrock.ts
  27. +20 −3 src/api/providers/cline.ts
  28. +40 −0 src/api/providers/litellm.ts
  29. +12 −2 src/api/providers/openai.ts
  30. +22 −5 src/api/providers/openrouter.ts
  31. +3 −0 src/api/transform/openrouter-stream.ts
  32. +87 −67 src/core/Cline.ts
  33. +1 −1 src/core/assistant-message/index.ts
  34. +120 −0 src/core/context-management/ContextManager.ts
  35. +10 −0 src/core/context-management/context-error-handling.ts
  36. +4 −1 src/core/mentions/index.ts
  37. +7 −7 src/core/prompts/system.ts
  38. +0 −97 src/core/sliding-window/index.ts
  39. +205 −46 src/core/webview/ClineProvider.ts
  40. +288 −0 src/dev/commands/tasks.ts
  41. +202 −11 src/extension.ts
  42. +8 −0 src/global-constants.ts
  43. +3 −2 src/integrations/checkpoints/CheckpointTracker.ts
  44. +0 −1 src/integrations/editor/DiffViewProvider.ts
  45. +1 −3 src/integrations/misc/link-preview.ts
  46. +118 −0 src/services/account/ClineAccountService.ts
  47. +5 −5 src/services/browser/BrowserSession.ts
  48. +7 −1 src/services/glob/list-files.ts
  49. +162 −159 src/services/mcp/McpHub.ts
  50. +17 −0 src/services/telemetry/TelemetryService.ts
  51. +18 −0 src/shared/ClineAccount.ts
  52. +23 −12 src/shared/ExtensionMessage.ts
  53. +4 −1 src/shared/WebviewMessage.ts
  54. +74 −4 src/shared/api.ts
  55. +21 −0 src/utils/storage.ts
  56. +628 −102 webview-ui/package-lock.json
  57. +5 −2 webview-ui/package.json
  58. +2 −1 webview-ui/src/App.tsx
  59. +11 −0 webview-ui/src/assets/ClineLogoWhite.tsx
  60. +123 −125 webview-ui/src/components/account/AccountView.tsx
  61. +114 −0 webview-ui/src/components/account/CreditsHistoryTable.tsx
  62. +8 −20 webview-ui/src/components/chat/Announcement.tsx
  63. +130 −0 webview-ui/src/components/chat/ChatErrorBoundary.tsx
  64. +6 −27 webview-ui/src/components/chat/ChatRow.tsx
  65. +15 −3 webview-ui/src/components/chat/ChatView.tsx
  66. +1 −1 webview-ui/src/components/chat/CreditLimitError.tsx
  67. +22 −12 webview-ui/src/components/chat/TaskHeader.tsx
  68. +15 −22 webview-ui/src/components/common/DangerButton.tsx
  69. +20 −25 webview-ui/src/components/common/SuccessButton.tsx
  70. +8 −4 webview-ui/src/components/history/HistoryView.tsx
  71. +336 −0 webview-ui/src/components/mcp/ImagePreview.tsx
  72. +345 −141 webview-ui/src/components/mcp/LinkPreview.tsx
  73. +199 −223 webview-ui/src/components/mcp/McpResponseDisplay.tsx
  74. +183 −0 webview-ui/src/components/mcp/McpRichUtil.ts
  75. +5 −3 webview-ui/src/components/mcp/McpToolRow.tsx
  76. +59 −8 webview-ui/src/components/mcp/McpView.tsx
  77. +683 −0 webview-ui/src/components/mcp/RICH_MCP_TESTING.md
  78. +78 −10 webview-ui/src/components/settings/ApiOptions.tsx
  79. +70 −0 webview-ui/src/components/settings/ClineAccountInfoCard.tsx
  80. +9 −4 webview-ui/src/components/settings/OpenRouterModelPicker.tsx
  81. +2 −19 webview-ui/src/components/welcome/WelcomeView.tsx
  82. +7 −0 webview-ui/src/context/ExtensionStateContext.tsx
  83. +24 −0 webview-ui/src/utils/format.ts
  84. +4 −0 webview-ui/vite.config.ts
7 changes: 0 additions & 7 deletions .changeset/.mighty-tools-remain.md

This file was deleted.

5 changes: 5 additions & 0 deletions .changeset/breezy-items-bake.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"claude-dev": minor
---

improving search and replace edit failure behaviors
5 changes: 5 additions & 0 deletions .changeset/chatty-scissors-rescue.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"claude-dev": patch
---

Update Google Gemini API key link
5 changes: 5 additions & 0 deletions .changeset/dirty-rice-film.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"claude-dev": minor
---

added telemetry to track replace_in_file tool failures
5 changes: 5 additions & 0 deletions .changeset/fluffy-pants-jog.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"claude-dev": minor
---

feat(extension): add access to history, mcp, and new task buttons in popout view
5 changes: 5 additions & 0 deletions .changeset/little-tomatoes-drive.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"claude-dev": minor
---

Support connecting to SSE servers
5 changes: 5 additions & 0 deletions .changeset/mighty-pants-sort.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"claude-dev": patch
---

Move the MCP Restart and Delete buttons and add an auto-approve all toggle
5 changes: 5 additions & 0 deletions .changeset/nasty-radios-dance.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"claude-dev": patch
---

updated gemini-2.0-pro-exp-02-05 to gemini-2.5-pro-exp-03-25 for Vertex AI
5 changes: 5 additions & 0 deletions .changeset/tall-rivers-knock.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"claude-dev": minor
---

Add toggle disabled for remote servers
2 changes: 1 addition & 1 deletion .clinerules
Original file line number Diff line number Diff line change
@@ -252,7 +252,7 @@ class Cline {
} catch (error) {
// 4. Error handling with retry
if (isOpenRouter && !this.didAutomaticallyRetryFailedApiRequest) {
await delay(1000)
await setTimeoutPromise(1000)
this.didAutomaticallyRetryFailedApiRequest = true
yield* this.attemptApiRequest(previousApiReqIndex)
return
2 changes: 1 addition & 1 deletion .github/CODEOWNERS
Original file line number Diff line number Diff line change
@@ -1 +1 @@
* @saoudrizwan @ocasta181 @NightTrek @pashpashpash @dcbartlett
* @saoudrizwan @ocasta181 @NightTrek @pashpashpash @dcbartlett @saito-sv
88 changes: 32 additions & 56 deletions .github/scripts/overwrite_changeset_changelog.py
Original file line number Diff line number Diff line change
@@ -22,7 +22,6 @@
#!/usr/bin/env python3

import os
import sys

CHANGELOG_PATH = os.environ.get("CHANGELOG_PATH", "CHANGELOG.md")
VERSION = os.environ['VERSION']
@@ -32,72 +31,49 @@
def overwrite_changelog_section(changelog_text: str, new_content: str):
# Find the section for the specified version
version_pattern = f"## {VERSION}\n"
bracketed_version_pattern = f"## [{VERSION}]\n"
unformmatted_prev_version_pattern = f"## {PREV_VERSION}\n"
prev_version_pattern = f"## [{PREV_VERSION}]\n"
print(f"latest version: {VERSION}")
print(f"prev_version: {PREV_VERSION}")

# Try both unbracketed and bracketed version patterns
version_index = changelog_text.find(version_pattern)
if version_index == -1:
version_index = changelog_text.find(bracketed_version_pattern)
if version_index == -1:
# If version not found, add it at the top (after the first line)
first_newline = changelog_text.find('\n')
if first_newline == -1:
# If no newline found, just prepend
return f"## [{VERSION}]\n\n{changelog_text}"
return f"{changelog_text[:first_newline + 1]}## [{VERSION}]\n\n{changelog_text[first_newline + 1:]}"
else:
# Using bracketed version
version_pattern = bracketed_version_pattern

notes_start_index = version_index + len(version_pattern)
notes_end_index = changelog_text.find(prev_version_pattern, notes_start_index) if PREV_VERSION and prev_version_pattern in changelog_text else len(changelog_text)
notes_start_index = changelog_text.find(version_pattern) + len(version_pattern)
notes_end_index = changelog_text.find(prev_version_pattern, notes_start_index) if PREV_VERSION and (prev_version_pattern in changelog_text or unformmatted_prev_version_pattern in changelog_text) else len(changelog_text)

if new_content:
return changelog_text[:notes_start_index] + f"{new_content}\n" + changelog_text[notes_end_index:]
else:
changeset_lines = changelog_text[notes_start_index:notes_end_index].split("\n")
# Ensure we have at least 2 lines before removing them
if len(changeset_lines) < 2:
print("Warning: Changeset content has fewer than 2 lines")
parsed_lines = "\n".join(changeset_lines)
else:
# Remove the first two lines from the regular changeset format, ex: \n### Patch Changes
parsed_lines = "\n".join(changeset_lines[2:])
updated_changelog = changelog_text[:notes_start_index] + parsed_lines + changelog_text[notes_end_index:]
# Ensure version number is bracketed
updated_changelog = updated_changelog.replace(f"## {VERSION}", f"## [{VERSION}]")
return updated_changelog
filtered_lines = []
for line in changeset_lines:
# If the previous line is a changeset format
if len(filtered_lines) > 1 and filtered_lines[-1].startswith("### "):
# Remove the last two lines from the filted_lines
filtered_lines.pop()
filtered_lines.pop()
else:
filtered_lines.append(line.strip())

try:
print(f"Reading changelog from: {CHANGELOG_PATH}")
with open(CHANGELOG_PATH, 'r') as f:
changelog_content = f.read()
# Prepend a new line to the first line of filtered_lines
if filtered_lines:
filtered_lines[0] = "\n" + filtered_lines[0]

print(f"Changelog content length: {len(changelog_content)} characters")
print("First 200 characters of changelog:")
print(changelog_content[:200])
print("----------------------------------------------------------------------------------")
# Print filted_lines wiht a "\n" at the end of each line
for line in filtered_lines:
print(line.strip())

parsed_lines = "\n".join(line for line in filtered_lines)
updated_changelog = changelog_text[:notes_start_index] + parsed_lines + changelog_text[notes_end_index:]
return updated_changelog

new_changelog = overwrite_changelog_section(changelog_content, NEW_CONTENT)

print("New changelog content:")
print("----------------------------------------------------------------------------------")
print(new_changelog)
print("----------------------------------------------------------------------------------")

print(f"Writing updated changelog back to: {CHANGELOG_PATH}")
with open(CHANGELOG_PATH, 'w') as f:
f.write(new_changelog)
with open(CHANGELOG_PATH, 'r') as f:
changelog_content = f.read()

print(f"{CHANGELOG_PATH} updated successfully!")
new_changelog = overwrite_changelog_section(changelog_content, NEW_CONTENT)
# print("----------------------------------------------------------------------------------")
# print(new_changelog)
# print("----------------------------------------------------------------------------------")
# Write back to CHANGELOG.md
with open(CHANGELOG_PATH, 'w') as f:
f.write(new_changelog)

except FileNotFoundError:
print(f"Error: Changelog file not found at {CHANGELOG_PATH}")
sys.exit(1)
except Exception as e:
print(f"Error updating changelog: {str(e)}")
print(f"Current working directory: {os.getcwd()}")
sys.exit(1)
print(f"{CHANGELOG_PATH} updated successfully!")
91 changes: 91 additions & 0 deletions .github/workflows/changeset-converter.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,91 @@
name: Changeset Converter
run-name: Changeset Conversion

on:
pull_request:
types: [closed]

env:
REPO_PATH: ${{ github.repository }}
GIT_REF: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || 'main' }}
NODE_VERSION: 20.18.1

jobs:
# Job 1: Create version bump PR when changesets are merged to main
changeset-pr-version-bump:
if: >
github.event_name == 'pull_request' &&
github.event.pull_request.merged == true &&
github.event.pull_request.base.ref == 'main' &&
github.actor != 'github-actions'
runs-on: ubuntu-latest
permissions:
contents: write
pull-requests: write
steps:
- name: Git Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
ref: ${{ env.GIT_REF }}

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: ${{ env.NODE_VERSION }}
cache: "npm"

- name: Install Dependencies
run: npm install changeset

# Check if there are any new changesets to process
- name: Check for changesets
id: check-changesets
run: |
NEW_CHANGESETS=$(find .changeset -name "*.md" ! -name "README.md" | wc -l | tr -d ' ')
echo "Changesets diff with previous version: $NEW_CHANGESETS"
echo "new_changesets=$NEW_CHANGESETS" >> $GITHUB_OUTPUT
# Create version bump PR using changesets/action if there are new changesets
- name: Create Changeset Pull Request
if: steps.check-changesets.outputs.new_changesets != '0'
uses: changesets/action@v1
with:
commit: "changeset version bump"
title: "Changeset version bump"
version: npm run version-packages # This performs the changeset version bump
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

# Get current and previous versions to edit changelog entry
- name: Get version
id: get_version
run: |
VERSION=$(git show HEAD:package.json | jq -r '.version')
echo "version=$VERSION" >> $GITHUB_OUTPUT
PREV_VERSION=$(git show origin/main:package.json | jq -r '.version')
echo "prev_version=$PREV_VERSION" >> $GITHUB_OUTPUT
echo "version=$VERSION"
echo "prev_version=$PREV_VERSION"
# Update CHANGELOG.md with proper format
- name: Update Changelog Format
env:
VERSION: ${{ steps.get_version.outputs.version }}
PREV_VERSION: ${{ steps.get_version.outputs.prev_version }}
run: python .github/scripts/overwrite_changeset_changelog.py

# Commit and push changelog updates
- name: Push Changelog updates to Pull Request
run: |
git config user.name "github-actions"
git config user.email github-actions@github.com
echo "Running git add and commit..."
git add CHANGELOG.md
git commit -m "Updating CHANGELOG.md format"
git status
echo "--------------------------------------------------------------------------------"
echo "Pushing to remote..."
echo "--------------------------------------------------------------------------------"
CURRENT_BRANCH=$(git rev-parse --abbrev-ref HEAD)
git push origin $CURRENT_BRANCH
117 changes: 0 additions & 117 deletions .github/workflows/check-changeset.yml

This file was deleted.

1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
out
coverage
dist
node_modules
tmp
Loading