• Visitors can check out the Forum FAQ by clicking this link. You have to register before you can post: click the REGISTER link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. View our Forum Privacy Policy.
  • FREE workshop: Preparing contractors for Autumn : Weds 29th Sep at 7.15pm. More details here.

LFORMAT in MS-DOS?

Collapse
X
  •  
  • Filter
  • Time
  • Show
Clear All
new posts

    LFORMAT in MS-DOS?

    This one's for the slightly older generation..

    I seem to recall on MSDOS you could for example list a directory structure, but modify the output with LFORMAT="..." (Line Format?) e.g. to generate a batch file. Suppose I have a directory of .MOV files I want to convert to .mp4. I thought I could go something like this:

    DIR /b *.MOV LFORMAT="avconv.exe -i %1.MOV %1.mp4"

    which would produce (I seem to recall you could extract just the filename without extension somehow) :

    avconv.exe -i MOV_0001.MOV MOV_0001.mp4
    avconv.exe -i MOV_0002.MOV MOV_0002.mp4
    avconv.exe -i MOV_0003.MOV MOV_0003.mp4

    etc.

    Google produces nothing that I can see? Am I going mad?
    Originally posted by Nigel Farage MEP - 2016-06-24 04:00:00
    "I hope this victory brings down this failed project and leads us to a Europe of sovereign nation states, trading together, being friends together, cooperating together, and let's get rid of the flag, the anthem, Brussels, and all that has gone wrong."

    #2
    I don't recall that.

    The answer to your problem is to install a Unix-like shell so that you can fire up a (shell) command window and achieve what you want albeit with rather different commands. If you have no Unix Shell knowledge, it'll be hard to do, although many on here could tell you the commands you need to get the result you want.

    Comment


      #3
      What about using PowerShell, perhaps modify this guys script.

      https://perfp.wordpress.com/2010/08/...and-handbrake/

      Comment


        #4
        Could it be that LFORMAT was a batch file or other command on the system you remember using this on? MSDN has nothing about LFORMAT, but something like

        Code:
        DIR /b *.MOV | LFORMAT="avconv.exe -i %1.MOV %1.mp4"
        (note the | to pipe the DIR output into LFORMAT) would do what you describe, if you can find the missing LFORMAT command

        Comment


          #5
          Originally posted by rl4engc View Post
          Am I going mad?
          Yes.

          Instead of going back in time in your wonderful Time Machine you should go FORWARD and get next week's lottery numbers and share them with me.

          Comment


            #6
            Originally posted by Platypus View Post
            I don't recall that.

            The answer to your problem is to install a Unix-like shell so that you can fire up a (shell) command window and achieve what you want albeit with rather different commands. If you have no Unix Shell knowledge, it'll be hard to do, although many on here could tell you the commands you need to get the result you want.
            e.g.
            Code:
            $ for f in *.MOV; do avconv -i "$f" "${f%.*}.mp4"; done

            Comment


              #7
              Do it with a batch file.

              https://grumpybear.wordpress.com/201...s-in-a-folder/

              Should be pretty simple.

              Comment


                #8
                Originally posted by rl4engc View Post
                This one's for the slightly older generation..

                I seem to recall on MSDOS you could for example list a directory structure, but modify the output with LFORMAT="..." (Line Format?) e.g. to generate a batch file. Suppose I have a directory of .MOV files I want to convert to .mp4. I thought I could go something like this:

                DIR /b *.MOV LFORMAT="avconv.exe -i %1.MOV %1.mp4"

                which would produce (I seem to recall you could extract just the filename without extension somehow) :

                avconv.exe -i MOV_0001.MOV MOV_0001.mp4
                avconv.exe -i MOV_0002.MOV MOV_0002.mp4
                avconv.exe -i MOV_0003.MOV MOV_0003.mp4

                etc.

                Google produces nothing that I can see? Am I going mad?
                Take a look on this guy's site.
                I always use it for this sort of stuff.
                He does exactly what you want using substitution variables.

                http://www.robvanderwoude.com/batchfiles.php
                Don't believe it, until you see it!

                Comment

                Working...
                X