SlickEdit Community

SlickEdit Product Discussion => SlickEdit® => Topic started by: spongyryno on September 08, 2021, 03:12:10 pm

Title: PowerShell in markdown uses the wrong word delimiters
Post by: spongyryno on September 08, 2021, 03:12:10 pm
If I have a PowerShell (*.ps1) file, and I have a variable:

Code: [Select]
$foo = "hello"

If I place the cursor at the end of $foo and then use the keyboard to select the variable, the whole thing is selected correctly, including the dollar sign.

However, if I have the same thing as embedded PowerShell inside a markdown file (*.md):


Code: [Select]

```PowerShell
$foo = "hello"
```

...and I do the same thing, it does not include the dollar sign... even though that's a critical part of the variable name. How can I fix this?

I'm on SlickEdit 25.0.2.0, 64-bit.

Title: Re: PowerShell in markdown uses the wrong word delimiters
Post by: Clark on September 10, 2021, 12:39:36 am
You can work around this problem by adding $ to the Word chars for Markdown. Tools>Options>Languages>Web Authoring Languages>Markdown>General>Word chars

We might be able to automate this in the future. It's pretty involved because word matching is done in many places (including mouse operations).
Title: Re: PowerShell in markdown uses the wrong word delimiters
Post by: spongyryno on September 26, 2021, 04:11:52 am
This works. Thanks.  :)