0

I am using the split command in cshell to split a file into smaller files. Since the split command names the output files xaa,xab,xac.... i have to rename them. I want to store the split commands output files in an array so it is easier for me to rename them. How would I go about doing this?

  set num = grep -c "$error" all_filtered_errors 

  if(num >= 1000000)

  split -l 100000 all_filtered_errors
     
3
  • 1
    Reading man split would be a good place to start. It has options to add a filename prefix, and a suffix, and to use numeric, hex, or character sequencing of sufficient length. Commented Aug 30, 2022 at 14:45
  • 1
    What system / split implementation is it? I don't know of a split that takes a -c option. Commented Aug 30, 2022 at 14:47
  • please don't post a picture of text ... post the text instead Commented Aug 30, 2022 at 14:52

0

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.