Change:
Testing the following file in markdown the following content Explorer, rename the file . The link in markdown does not get updated
Hm, thought I already had a feature request tracking this but perhaps I repurposed that issue Yes this is not expected to work today as the provider is not involved at all in this flow. I'd expected rename on files to work much like how it does for JS/TS
Reopening since the feature is still experimental

Discussion:
"error" ] }, <del> "markdown.experimental.updateLinksOnFileMove.enabled": { </del> <ins> "markdown.updateLinksOnFileMove.enabled": { </ins> "type": "string", "enum": [ "prompt",

"never" ], "markdownEnumDescriptions": [ <del> "%configuration.markdown.experimental.updateLinksOnFileMove.enabled.prompt%", "%configuration.markdown.experimental.updateLinksOnFileMove.enabled.always%", "%configuration.markdown.experimental.updateLinksOnFileMove.enabled.never%" </del> <ins> "%configuration.markdown.updateLinksOnFileMove.enabled.prompt%", "%configuration.markdown.updateLinksOnFileMove.enabled.always%", "%configuration.markdown.updateLinksOnFileMove.enabled.never%" </ins> ], "default": "never", <del> "markdownDescription": "%configuration.markdown.experimental.updateLinksOnFileMove.enabled%", </del> <ins> "markdownDescription": "%configuration.markdown.updateLinksOnFileMove.enabled%", </ins> "scope": "resource", "tags": [ "experimental" ] }, <del> "markdown.experimental.updateLinksOnFileMove.externalFileGlobs": { </del> <ins> "markdown.updateLinksOnFileMove.externalFileGlobs": { </ins> "type": "string", "default": "**/*.{jpg,jpe,jpeg,png,bmp,gif,ico,webp,avif,tiff,svg,mp4}", <del> "description": "%configuration.markdown.experimental.updateLinksOnFileMove.fileGlobs%", </del> <ins> "description": "%configuration.markdown.updateLinksOnFileMove.fileGlobs%", </ins> "scope": "resource", "tags": [ "experimental" ] }, <del> "markdown.experimental.updateLinksOnFileMove.enableForDirectories": { </del> <ins> "markdown.updateLinksOnFileMove.enableForDirectories": { </ins> "type": "boolean", "default": true, <del> "description": "%configuration.markdown.experimental.updateLinksOnFileMove.enableForDirectories%", </del> <ins> "description": "%configuration.markdown.updateLinksOnFileMove.enableForDirectories%", </ins> "scope": "resource", "tags": [ "experimental"

"configuration.markdown.validate.ignoredLinks.description": "Configure links that should not be validated. For example adding `/about` would not validate the link `[about](/about)`, while the glob `/assets/**/*.svg` would let you skip validation for any link to `.svg` files under the `assets` directory.", "configuration.markdown.validate.unusedLinkDefinitions.description": "Validate link definitions that are unused in the current file.", "configuration.markdown.validate.duplicateLinkDefinitions.description": "Validate duplicated definitions in the current file.", <del> "configuration.markdown.experimental.updateLinksOnFileMove.enabled": "Try to update links in Markdown files when a file is renamed/moved in the workspace. Use `#markdown.experimental.updateLinksOnFileMove.externalFileGlobs#` to configure which files trigger link updates.", "configuration.markdown.experimental.updateLinksOnFileMove.enabled.prompt": "Prompt on each file move.", "configuration.markdown.experimental.updateLinksOnFileMove.enabled.always": "Always update links automatically.", "configuration.markdown.experimental.updateLinksOnFileMove.enabled.never": "Never try to update link and don't prompt.", "configuration.markdown.experimental.updateLinksOnFileMove.fileGlobs": "A glob that specifies which files besides markdown should trigger a link update.", "configuration.markdown.experimental.updateLinksOnFileMove.enableForDirectories": "enable/disable updating links when a directory is moved or renamed in the workspace.", </del> <ins> "configuration.markdown.updateLinksOnFileMove.enabled": "Try to update links in Markdown files when a file is renamed/moved in the workspace. Use `#markdown.updateLinksOnFileMove.externalFileGlobs#` to configure which files trigger link updates.", "configuration.markdown.updateLinksOnFileMove.enabled.prompt": "Prompt on each file move.", "configuration.markdown.updateLinksOnFileMove.enabled.always": "Always update links automatically.", "configuration.markdown.updateLinksOnFileMove.enabled.never": "Never try to update link and don't prompt.", "configuration.markdown.updateLinksOnFileMove.fileGlobs": "A glob that specifies which files besides markdown should trigger a link update.", "configuration.markdown.updateLinksOnFileMove.enableForDirectories": "enable/disable updating links when a directory is moved or renamed in the workspace.", </ins> "workspaceTrust": "Required for loading styles configured in the workspace." }

const localize = nls.loadMessageBundle(); const settingNames = Object.freeze({ <del> enabled: 'experimental.updateLinksOnFileMove.enabled', externalFileGlobs: 'experimental.updateLinksOnFileMove.externalFileGlobs', enableForDirectories: 'experimental.updateLinksOnFileMove.enableForDirectories', </del> <ins> enabled: 'updateLinksOnFileMove.enabled', externalFileGlobs: 'updateLinksOnFileMove.externalFileGlobs', enableForDirectories: 'updateLinksOnFileMove.enableForDirectories', </ins> }); const enum UpdateLinksOnFileMoveSetting {

super(); this._register(vscode.workspace.onDidRenameFiles(async (e) => { <del> for (const { newUri, oldUri } of e.files) { const config = vscode.workspace.getConfiguration('markdown', newUri); if (!await this.shouldParticipateInLinkUpdate(config, newUri)) { continue; </del> <ins> await Promise.all(e.files.map(async (rename) => { if (await this.shouldParticipateInLinkUpdate(rename.newUri)) { this._pendingRenames.add(rename); </ins> } <del> this._pendingRenames.add({ newUri, oldUri }); } </del> <ins> })); </ins> if (this._pendingRenames.size) { this._delayer.trigger(() => {

return false; } } <del> private async shouldParticipateInLinkUpdate(config: vscode.WorkspaceConfiguration, newUri: vscode.Uri): Promise<boolean> { </del> <ins> private async shouldParticipateInLinkUpdate(newUri: vscode.Uri): Promise<boolean> { const config = vscode.workspace.getConfiguration('markdown', newUri); </ins> const setting = config.get<UpdateLinksOnFileMoveSetting>(settingNames.enabled); if (setting === UpdateLinksOnFileMoveSetting.Never) { return false;

} } <del> export function registerUpdateLinksOnRename(client: MdLanguageClient) { </del> <ins> export function registerUpdateLinksOnRename(client: MdLanguageClient): vscode.Disposable { </ins> return new UpdateLinksOnFileRenameHandler(client); }