Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • 05:04
    msftbot[bot] labeled #2496
  • 05:04
    animehunter123 commented #2496
  • 05:00
    rjmholt commented #2491
  • 05:00
    TylerLeonhardt unlabeled #2496
  • 05:00
    rjmholt commented #2491
  • 05:00
    rjmholt commented #2491
  • 04:59
    rjmholt labeled #2496
  • 04:59
    rjmholt commented #2496
  • 04:58
    TylerLeonhardt commented #2495
  • 04:55
    rjmholt assigned #2495
  • 04:15
    animehunter123 edited #2496
  • 04:09
    msftbot[bot] labeled #2496
  • 04:09
    animehunter123 opened #2496
  • 02:26
    msftbot[bot] labeled #2495
  • 02:26
    Ayanmullick opened #2495
  • 02:20
    SeeminglyScience commented #2291
  • 01:50
    TylerLeonhardt commented #2491
  • 01:44
    TylerLeonhardt commented #2377
  • 01:36
    TylerLeonhardt commented #2291
  • 01:28
    rjmholt commented #2491
PowerShell Connect
@PoshConnect_twitter
BrettMiller (discord) Yeah pretty much
Corbob (discord) so it's just that PowerShell doesn't (currently) to the interpretation...
Corbob (discord) (not entirely sure interpolate is the word they want to use there... https://www.merriam-webster.com/dictionary/interpolate but 🤷 )
PowerShell Connect
@PoshConnect_twitter
gaelcolas (slack) I don't know for you but vscode-powershell 2020.2 seems to have broken the integrated terminal for me
PowerShell Connect
@PoshConnect_twitter
Roogon (discord) .. in what way?
PowerShell Connect
@PoshConnect_twitter
gaelcolas (slack) The terminal starts but hangs after the banner
gaelcolas (slack) Vscode does work though.
gaelcolas (slack) Reverting to the non preview extension works
PowerShell Connect
@PoshConnect_twitter
Corbob (discord) @gaelcolas not sure if it's related, but might want to poke Rob about this: PowerShell/vscode-powershell#2490
PowerShell Connect
@PoshConnect_twitter
This message was deleted
PowerShell Connect
@PoshConnect_twitter
rjmholt_msft (slack) @gaelcolas I've stopped being able to reproduce that issue -- it might have been a stale dev build on my machine that I was hitting. Do you think you could show me your logs (<kbd>Ctrl</kbd>+<kbd>Shift</kbd>+<kbd>P</kbd> and type Logs)
rjmholt_msft (slack) Ugh my cool HTML for keys didn't work
rjmholt_msft (slack) Hopefully the logs will give me some OS/PS information as well
PowerShell Connect
@PoshConnect_twitter
Ayan (discord) Is there any way one could point the VSC external terminal to the Microsoft Terminal?
https://cdn.discordapp.com/attachments/446531919644065804/681665577248489506/unknown.png
jborean93 (discord) IIRC the terminal is actually the shell to run. Microsoft Terminal is not a shell but a terminal to run shells in.
jborean93 (discord) I could be wrong there though
Ayan (discord) ok. I see.
Ayan (discord) Is there a way to run PowerShell scripts from the VSC script pane on an external PowerShell console?
jborean93 (discord) The powershell extension has an option to use an external console or the integrated one
PowerShell Connect
@PoshConnect_twitter
jborean93 (discord) hmm maybe not, it could be a generic option
Ayan (discord) I couldn't locate a PowerShell extension setting to point to the external terminal (edited)
Ayan (discord) I'm using the PowerShell Preview extension
PowerShell Connect
@PoshConnect_twitter
seeminglyscience (discord) you can set it up to launch a script in an external window, it just won't be hooked up to the language server at all
Ayan (discord) which settings should I configure for that? How do I set it up? (edited)
PowerShell Connect
@PoshConnect_twitter

seeminglyscience (discord) there's probably a better way but you could do something like:

# Put this in your $profile
Register-EditorCommand -Name 'RunFileInExternalWindow' -DisplayName 'Run current file in external window' -ScriptBlock {
    Start-Process pwsh('-File', $psEditor.GetEditorContext().CurrentFile.Path)
}

then in keybindings.json:

    {
        "key": "ctrl+shift+j",
        "command": "PowerShell.InvokeRegisteredEditorCommand",
        "args": [{ "commandName": "RunFileInExternalWindow" }],
        "when": "editorLangId == 'powershell'"
    },
}
PowerShell Connect
@PoshConnect_twitter
Ayan (discord) Does one need to manually create a keybindings.json file?
seeminglyscience (discord) do ctrl + shift + p and start typing Keyboard Shortcuts (JSON) until you see it in the list
seeminglyscience (discord) you could also use editor commands to launch an external console running the current selection using a similar technique. You'd want to use $psEditor.GetEditorContext().SelectedRange to get the selection, get the text of that selection, and pass it to an external process via -EncodedCommand
PowerShell Connect
@PoshConnect_twitter
seeminglyscience (discord) it's gotta be in the integrated console
seeminglyscience (discord) the one that the PowerShell extension starts
PowerShell Connect
@PoshConnect_twitter
Ayan (discord) Somehow no integrated terminal loading on VSC Insiders now 🙃
https://cdn.discordapp.com/attachments/446531919644065804/681677645372850244/unknown.png
Ayan (discord) looking into it.
seeminglyscience (discord) I think I've seen that every now and then with the latest preview, try reloading the window
PowerShell Connect
@PoshConnect_twitter
Ayan (discord) Nope. Reloading not helping with integrated terminal
seeminglyscience (discord) maybe try opening a different workspace? other than that maybe try vscode stable
Corbob (discord) Do you have an option to restart current session in the command palette?
PowerShell Connect
@PoshConnect_twitter
Ayan (discord) yes. But restarting current session didn't start integrated terminal.
Ayan (discord) I'm downloading a portable VSC to try the external terminal settings there
PowerShell Connect
@PoshConnect_twitter
Ayan (discord) Running in VSC portable. Still errors out on Integrated terminal (edited)
https://cdn.discordapp.com/attachments/446531919644065804/681681900913295430/unknown.png
PowerShell Connect
@PoshConnect_twitter
Ayan (discord) Just installed the PowerShell Preview extension and running on latest RC3
https://cdn.discordapp.com/attachments/446531919644065804/681683255048929307/unknown.png
seeminglyscience (discord) ah yeah some namespaces were changed, could you create an issue for that?
Ayan (discord) Yes Sure. Saying that Register-EditorCommand doesn't work on the new RC3 ?
seeminglyscience (discord) yeah, basically just copy paste those error messages and say it happens when running that command
seeminglyscience (discord) it's clear what it's from and should be an easy fix
PowerShell Connect
@PoshConnect_twitter
Ayan (discord) ok. And should I create a separate issue for how to set up running selected range from the VSC script pane on to the external terminal?
seeminglyscience (discord) nah there's already a ticket I think, one sec let me find it
seeminglyscience (discord) PowerShell/vscode-powershell#492
PowerShell Connect
@PoshConnect_twitter
Ayan (discord) Submitted
PowerShell/vscode-powershell#2495