diff --git a/CHANGELOG.md b/CHANGELOG.md index 0de0caa..373f478 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,13 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [0.13.0] - Unreleased + +### Added: + +- Snippets: `devproxy-plugin-rewrite` - RewritePlugin instance +- Snippets: `devproxy-plugin-rewrite-config` - RewritePlugin config section + ## [0.12.0] - 2024-10-31 > **Note**: `0.11.x` pre-releases are not included in this changelog. They were used to test the new features and fixes before the final release. diff --git a/README.md b/README.md index 5db79e9..6ee431e 100644 --- a/README.md +++ b/README.md @@ -131,6 +131,8 @@ Shown when the active document is a Dev Proxy configuration file | `devproxy-plugin-rate-limiting-file` | Dev Proxy rate limiting file | | `devproxy-plugin-rate-limiting-file-schema` | Dev Proxy rate limiting file schema | | `devproxy-plugin-retry-after` | RetryAfterPlugin instance | +| `devproxy-plugin-rewrite` | RewritePlugin instance | +| `devproxy-plugin-rewrite-config` | RewritePlugin config section | | `devproxy-reporter-json` | JsonReporter instance | | `devproxy-reporter-markdown` | MarkdownReporter instance | | `devproxy-reporter-plain-text` | PlainTextReporter instance | diff --git a/package-lock.json b/package-lock.json index bb510b0..5d9d0bf 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "dev-proxy-toolkit", - "version": "0.12.0", + "version": "0.13.0", "lockfileVersion": 3, "requires": true, "packages": { diff --git a/package.json b/package.json index f15e72a..021a63c 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "name": "dev-proxy-toolkit", "displayName": "Dev Proxy Toolkit", "description": "Makes it easy to create and update Dev Proxy configuration files.", - "version": "0.12.0", + "version": "0.13.0", "publisher": "garrytrinder", "engines": { "vscode": "^1.89.0" diff --git a/src/constants.ts b/src/constants.ts index 715107b..7b60102 100644 --- a/src/constants.ts +++ b/src/constants.ts @@ -160,6 +160,13 @@ export const pluginSnippets: PluginSnippets = { RetryAfterPlugin: { instance: 'devproxy-plugin-retry-after', }, + RewritePlugin: { + instance: 'devproxy-plugin-rewrite', + config: { + name: 'devproxy-plugin-rewrite-config', + required: true, + } + }, JsonReporter: { instance: 'devproxy-reporter-json', }, @@ -288,6 +295,10 @@ export const pluginDocs: PluginDocs = { name: 'Retry After Plugin', url: 'https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/technical-reference/retryafterplugin', }, + RewritePlugin: { + name: 'Rewrite Plugin', + url: 'https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/technical-reference/rewriteplugin', + }, JsonReporter: { name: 'JSON Reporter', url: 'https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/technical-reference/jsonreporter', diff --git a/src/snippets.json b/src/snippets.json index 2b1f6be..301409d 100644 --- a/src/snippets.json +++ b/src/snippets.json @@ -848,6 +848,27 @@ ], "description": "RetryAfterPlugin instance" }, + "RewritePlugin": { + "prefix": "devproxy-plugin-rewrite", + "body": [ + "{", + "\t\"name\": \"RewritePlugin\",", + "\t\"enabled\": true,", + "\t\"pluginPath\": \"~appFolder/plugins/dev-proxy-plugins.dll\",", + "\t\"configSection\": \"rewritePlugin\"", + "}" + ], + "description": "RewritePlugin instance" + }, + "RewritePluginConfig":{ + "prefix": "devproxy-plugin-rewrite-config", + "body": [ + "\"rewritePlugin\": {", + "\t\"rewritesFile\": \"rewrites.json\"", + "}" + ], + "description": "RewritePlugin config section" + }, "JsonReporter": { "prefix": "devproxy-reporter-json", "body": [