Windows equivalent of 'touch' (i.e. the node.js way to create an index.html)

后端 未结 19 2235
一整个雨季
一整个雨季 2020-11-28 00:47

On a windows machine I get this error

\'touch\' is not recognized as an internal or external command, operable program or batch file.

19条回答
  •  离开以前
    2020-11-28 01:29

    Use the following command on the your command line:

    fsutil file createnew filename  requiredSize
    

    The parameters info as followed:

    fsutil - File system utility ( the executable you are running )

    file - triggers a file action

    createnew - the action to perform (create a new file)

    filename - would be literally the name of the file

    requiredSize - would allocate a file size in bytes in the created file

提交回复
热议问题