HiveBrain v1.2.0
Get Started
← Back to all entries
snippetbashTip

mkfile — Create empty files of any size. More information: <https://manned.org/mkfile>.

Submitted by: @import:tldr-pages··
0
Viewed 0 times
createcommandanyfilesemptyclisizemkfile

Problem

How to use the mkfile command: Create empty files of any size. More information: <https://manned.org/mkfile>.

Solution

mkfile — Create empty files of any size. More information: <https://manned.org/mkfile>.

Create an empty file of 15 kilobytes:
mkfile -n {{15k}} {{path/to/file}}


Create a file of a given size and unit (bytes, KB, MB, GB):
mkfile -n {{size}}{{b|k|m|g}} {{path/to/file}}


Create two files of 4 megabytes each:
mkfile -n {{4m}} {{first_filename}} {{second_filename}}

Code Snippets

Create an empty file of 15 kilobytes

mkfile -n {{15k}} {{path/to/file}}

Create a file of a given size and unit (bytes, KB, MB, GB)

mkfile -n {{size}}{{b|k|m|g}} {{path/to/file}}

Create two files of 4 megabytes each

mkfile -n {{4m}} {{first_filename}} {{second_filename}}

Context

tldr-pages: common/mkfile

Revisions (0)

No revisions yet.