Adjust a Textfile in a Remote session

Welcome Forums General PowerShell Q&A Adjust a Textfile in a Remote session

This topic contains 4 replies, has 2 voices, and was last updated by

 
Participant
3 years, 4 months ago.

  • Author
    Posts
  • #29529

    Participant
    Points: 0
    Rank: Member

    Hi There,

    I am wondering if someone has any good ideas for adjusting .ps1 or other files over a remote session.

    i have found vim or vi for windows, but this would force me to install vi or vim on every server we have.

    Maybe someone has a good idea or solution.

    Regards,
    Ferry

  • #29530

    Keymaster
    Points: 1,785
    Helping HandTeam Member
    Rank: Community Hero

    If you mean, "console text editor," in v4 or earlier, no. There's definitely nothing native. Although, forget Remoting and just open the file via UNC.

  • #29531

    Participant
    Points: 0
    Rank: Member

    Hi Don, thanks for your quick reply.

    That is what i meant indeed.

    in v4 or earlier no, ok i can live with that.
    in v5 yes? or still no options.

    The problem we face is that UNC is not always allowed trough firewall configurations.
    Thanks.

  • #29533

    Keymaster
    Points: 1,785
    Helping HandTeam Member
    Rank: Community Hero

    Remoting in 5 gains the ability to copy files over the WSMAN channel. So while that still doesn't enable a local editor on the remote box, it means the ISE on your workstation can grab the file via Remoting, edit it, and save it back to the remote box more or less seamlessly. I think Snover did a demo at PowerShell Summit 2015 – it'll be on our YouTube channel in his session recording, I think. Unless it was NDA at the time,

  • #29536

    Participant
    Points: 0
    Rank: Member

    From a different video i saw something we can use.

    if you use remoting from ISE, you can use the psedit command to open your files.

    Thanks Don!

The topic ‘Adjust a Textfile in a Remote session’ is closed to new replies.