geddski / geddski/macros

After last VS Code update, something doesn't works fine

Open
#53 3 comments 1 reaction 0 assignees View on GitHub
Dominant language
JavaScript
Stars
177
Forks
36
PR merge metrics
No merged PRs in 30d

Description

I'm using this extension from 8 months, but I think from last VS code version 1.37.1 my macro doesn't work anymore.
${CLIPBOARD} is not replaced anymore from selected text. In some case all snippet is pasted replacing all document text instead insert it after the newline.

Anyone can help me?

settings.json

`

"macros": {
"printr": [
"editor.action.smartSelect.grow",
"editor.action.clipboardCopyAction",
"editor.action.insertLineAfter",
{
"command": "editor.action.insertSnippet",
"args": {
"name": "customprintr",
"langId": "php",
}
},
"editor.action.insertLineAfter",
"editor.action.clipboardCopyAction",
]
},
`

snippets/php.json

`

"customprintr": {
"prefix": "customprintr",
"body": [
"\t",
"\t echo '

';",

"\t \\$printMe = ${CLIPBOARD}; print_r(\\$printMe);",
"\t echo '
';",
"\t die;",
"\t",
"\t"
],
"description": "Insert custom print_r"
},
"br": {
"prefix": "br",
"body": ["
"]
}
`

Contributor guide

No contributing guide indexed for this repository

Research direction

Reproduce the macro from settings.json with the snippets/php.json customprintr snippet under the reported VS Code 1.37.1 setup. Investigate why ${CLIPBOARD} is no longer replaced and why insertion can replace the document; done means both behaviors work correctly without breaking the existing macro sequence.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, vscode
Domain
developer-experience, devtools
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.