Difference between revisions of "Split (command)"

From wikieduonline
Jump to navigation Jump to search
Tags: Mobile web edit, Mobile edit
 
(14 intermediate revisions by 2 users not shown)
Line 1: Line 1:
<code>split</code> command splits a [[file]] into pieces. Default size is 1000 [[lines]]
+
{{lowercase}}
 +
<code>[[wikipedia:split (Unix)]]</code> command splits a [[file]] into pieces. Default size is 1000 [[lines]]
  
 
http://man7.org/linux/man-pages/man1/split.1.html
 
http://man7.org/linux/man-pages/man1/split.1.html
  
  split file_name
+
  split filename_to_split
 
  (no output and file_name has been splitted)
 
  (no output and file_name has been splitted)
  
  split -b 500M file_name
+
split filename_to_split [[--verbose]]
 +
 
 +
  split -b 500M filename_to_split
 +
(no output and file_name has been splitted)
 +
 
 +
split -b 1G filename_to_split
 
  (no output and file_name has been splitted)
 
  (no output and file_name has been splitted)
  
  split -n  
+
* Generate n chunks output files with <code>-n</code> flag
   
+
  split -n
 +
  split -n5 filename_to_split
 +
 
 
== Related terms ==
 
== Related terms ==
 
* <code>[[truncate]]</code>
 
* <code>[[truncate]]</code>
 
* <code>[[cat]]</code>
 
* <code>[[cat]]</code>
* <code>[[coreutils]]</code>
+
* <code>[[coreutils]]</code> package
 +
* <code>[[csplit]]</code>
 +
* <code>[[logrotate]]</code>
 +
* [[Split window]]
 +
* [[Terraform split]]
  
 
== See also ==
 
== See also ==
 +
* {{split}}
 
* {{cat}}
 
* {{cat}}
 
* {{files}}
 
* {{files}}

Latest revision as of 13:35, 11 March 2024

wikipedia:split (Unix) command splits a file into pieces. Default size is 1000 lines

http://man7.org/linux/man-pages/man1/split.1.html

split filename_to_split
(no output and file_name has been splitted)
split filename_to_split --verbose
split -b 500M filename_to_split
(no output and file_name has been splitted)
split -b 1G filename_to_split
(no output and file_name has been splitted)
  • Generate n chunks output files with -n flag
split -n
split -n5 filename_to_split

Related terms[edit]

See also[edit]

Advertising: