2

There is script command on GNU/Linux machine which allows to capture all command line activity into a file . This is really helpful tool especially when we learn something new and we want to save the commands and their output for future reference.

I am currently learning the Git on Windows PowerShell terminal and I wanted to capture all the commands and their output in a file for future reference.

Is there any way/command do achieve it on Windows PowerShell?

Mantosh Kumar
  • 5,475
  • 3
  • 22
  • 46

2 Answers2

5

It exists standard CmdLets : Start-Transcript and Stop-Transcript.

You'll find more informations about these CmdLet in the associeted TechNet documentation.

JPBlanc
  • 67,114
  • 13
  • 128
  • 165
  • 1
    I answered first, but @why answer is more complete. – JPBlanc Sep 07 '14 at 08:07
  • no your answer is more complete because the documentation ( merci beaucoup mais c'est ton mérite moi je n'ai fait que répété ce que t'as dit en premier) – walid toumi Sep 08 '14 at 05:11
5

Try with Start-Transcript and Stop-Transcript cmdlet.

You can also use Start-Transcript for ISE Editor module because these CmdLet don't work natively in ISE.

JPBlanc
  • 67,114
  • 13
  • 128
  • 165
walid toumi
  • 2,052
  • 1
  • 10
  • 10