I'm new and still trying to figure out how to configure my development environment. I'm getting an error when using the touch command in Visual Studio Code. I can use mkdir
to create a directory, but can't create a .php
file. Here's the error I'm getting. Any ideas? Thank you!
touch : The term 'touch' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again. At line:1 char:1 + touch new.php + ~~~~~ + CategoryInfo : ObjectNotFound: (touch:String) [], CommandNotFoundException + FullyQualifiedErrorId : CommandNotFoundException
If your terminal is set to run as administrator only, and you are not launching VS Code as administrator, the terminal will not be able to open. You can either change the default terminal or edit the properties of the terminal exe to not run as administrator.
In computing, touch is a command used to update the access date and/or modification date of a computer file or directory.
if you use git then, go to the folder of your project where you want to create a file, then right click and chose "git bash here". a terminal/command prompt type window will appear now you can type command "touch .newfilename".
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With