---
title: "How would you create a text file without opening it?"  
description: "How would you create a text file without opening it?"  
author: "Mukul Goenka"  
published: 2022-04-15  
canonical: https://answers.mindstick.com/qa/96837/how-would-you-create-a-text-file-without-opening-it  
category: "troubleshooting"  
tags: ["troubleshooting", "linux"]  
reading_time: 1 minute  

---

# How would you create a text file without opening it?

How would you create a [text](https://www.mindstick.com/blog/301635/did-people-reinvent-texting-to-express-the-full-range-of-emotions) [file](https://www.mindstick.com/articles/59/encrypting-and-decrypting-files-using-c-sharp) without opening it?

## Answers

### Answer by Hitesh Vohra

- Fill in whatever text you like in the file, then **select File, then Save** (or press Ctrl + S on the computer) in the top-right menu. Click Save after choosing a file name and location.
- To create a text file with touch, type $ touch NewFile.txt.
- To make a new file, type $ cat NewFile.txt. …
- To create a text file, simply type $ > NewFile.txt.
- Finally, we can create the file with any text editor name, such as:

\

**Read More: [How would you delete a directory in Linux?](https://answers.mindstick.com/qa/96838/how-would-you-delete-a-directory-in-linux)**


---

Original Source: https://answers.mindstick.com/qa/96837/how-would-you-create-a-text-file-without-opening-it

Copyright © MindStick Software Pvt. Ltd. This Markdown version is provided for developers, AI systems, and offline reading.
