'touch' is not recognized as an internal o

2020-02-08 10:14发布

I work with laravel 5 , when i type in windows cmd this command "touch storage\database.sqlite" this error message rise 'touch' is not recognized as an internal or external command, operable program or batch file. any hint to solve it ?

9条回答
女痞
2楼-- · 2020-02-08 10:38

, used with copy to indicate missing parameters. This updates the files modified date. E.G. copy /b file1,,

查看更多
甜甜的少女心
3楼-- · 2020-02-08 10:41

The command you're trying to run is a unix/linux based command so it won't work in Windows.

All it does is update the modified timestamps of a file.

There's another question on here that gives you an alternative for Windows: https://superuser.com/questions/10426/windows-equivalent-of-the-linux-command-touch/764716

查看更多
Fickle 薄情
4楼-- · 2020-02-08 10:43

You can just use echo> in windows cmd i.epath/file.sqlite

查看更多
放荡不羁爱自由
5楼-- · 2020-02-08 10:45

If you are trying to use TypeScript in ReactNative first run:

npm install touch-cli -g

and then you can use touch, example:

touch rn-cli.config.js
查看更多
来,给爷笑一个
6楼-- · 2020-02-08 10:48

If you are on windows device just install git bash and type the following command

touch test.html.

The above command will generate a zero kilobyte test.html file for you in your specified directory. It is applicable to any other type of file.

查看更多
家丑人穷心不美
7楼-- · 2020-02-08 10:53

Fixed after running this command:

npm install touch-cli -g

After that I can run this:

touch .babelrc
查看更多
登录 后发表回答