---
title: "Create-File"
---
Creates a file on a server.
Create-File(
	Name: <text>,
	[Text: <text>],
	[Overwrite: <true/false>],
	[FileMode: <text>]
);
This operation may be prefixed with Files::, although this is a built-in namespace and isn't really necessary.
| Name | Format | Script Usage | Usage Notes | 
|---|---|---|---|
| ☆ File name (default) | text | Name | The path of the file to create. This argument is required. | 
| Text | text | Text | |
| Overwrite | true/false | Overwrite | |
| File mode | text | FileMode | The octal file mode for the file. This value is ignored on Windows. | 
# write the name of the current working directory to my desktop
Create-File(
    Name: C:\Users\atripp\Desktop\workingdir.txt,
    Text: $WorkingDirectory
);