how to create a new file in a directory using terminal windows code example Example: create file and write to it cmd echo some-text > filename.txt