Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8263171
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T04:00:51+00:00 2026-06-08T04:00:51+00:00

In Powershell I run some command-line script and make a dump of it: PS>

  • 0

In Powershell I run some command-line script and make a dump of it:

PS> cmd /c D:\script.bat | tee ~/out.log

Then, I open this log in vim, and this is roughly what I see:

яю^M^@
^@C^@:^@\^@U^@s^@e^@r^@s^@>^@s^@e^@t^@ ^@D^@E^@B^@U^@G^@_^@F^@U^@L^@F^@I^@L^@L^@M^@E^@N^@T^@=^@-^@X^@r^@u^@n^@j^@d^@w^@p^@:^@t^@r^@a^@n^@s^@p^@o^@r^@t^@=^@d^@t^@_^@s^@o^@c^@k^@e^@t^@,^@a^@d^@d^@r^@e^@s^@s^@=^@3^@0^@0^@4^@,^@s^@e^@r^@v^@e^@r^@=^@y^@,^@s^@u^@s^@p^@e^@n^@d^@=^@n^@ ^@^M^@

And the hex dump:

0000000: d18f d18e 0d00 0a00 4300 3a00 5c00 5500  ........C.:.\.U.
0000010: 7300 6500 7200 7300 3e00 7300 6500 7400  s.e.r.s.>.s.e.t.
0000020: 2000 4400 4500 4200 5500 4700 5f00 4600   .D.E.B.U.G._.F.
0000030: 5500 4c00 4600 4900 4c00 4c00 4d00 4500  U.L.F.I.L.L.M.E.
0000040: 4e00 5400 3d00 2d00 5800 7200 7500 6e00  N.T.=.-.X.r.u.n.
0000050: 6a00 6400 7700 7000 3a00 7400 7200 6100  j.d.w.p.:.t.r.a.
0000060: 6e00 7300 7000 6f00 7200 7400 3d00 6400  n.s.p.o.r.t.=.d.
0000070: 7400 5f00 7300 6f00 6300 6b00 6500 7400  t._.s.o.c.k.e.t.
0000080: 2c00 6100 6400 6400 7200 6500 7300 7300  ,.a.d.d.r.e.s.s.
0000090: 3d00 3300 3000 3000 3400 2c00 7300 6500  =.3.0.0.4.,.s.e.
00000a0: 7200 7600 6500 7200 3d00 7900 2c00 7300  r.v.e.r.=.y.,.s.
00000b0: 7500 7300 7000 6500 6e00 6400 3d00 6e00  u.s.p.e.n.d.=.n.
00000c0: 2000 0d00 0a                              ....

How do I configure vim to open such files normally without a hassle of deleting those nulls every time?
P.S. Notepad opens file without nulls visible

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-08T04:00:52+00:00Added an answer on June 8, 2026 at 4:00 am

    It seems that your file is UTF8 encoded.

    To open it, start vim with encoding argument like this:

    vim "+set encoding=utf-8"
    

    or if you are already editing the file, you can set the encoding as follows:

    :set enc=utf-8
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

The recommended way to run scripts is powershell.exe -NonInteractive -Command & some.ps1 However for
Trying to run the following command in php to run powershell command... the following
Currently I'm trying to run this powershell script: Param ( $websiteName, $physicalPath ) import-module
I'm using powershell script to run a few *.sql file. I can get the
I'd like to use a windows PowerShell script to run a batch file every
I'm trying to run the following PowerShell script to create a local user. This
I have a complex Powershell script that gets run as part of a SQL
I'm looking to run some powershell scripts via automation. Something like: IList errors; Collection<PSObject>
I'm a Powershell newbie, trying to get a simple script to run. I have
When you install a package from NuGet, it can run some Powershell scripts to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.