Combine Files using BBEdit
Easy way to Combine Files in MacOS
Earlier this week I had a bunch of Apache log files that I wanted to combine into a single file. I was trying to figure out the best way to do it. A quick Google search showed me a solution from 2014. The purpose of this post is to say that it still works!
In BBEdit
Here are the steps to quickly merge a bunch of files:
- Open up BBEdit
- Create a new Text Document (Command N)
- Go Under Edit menu and select Insert then 'File Contents...'
- Select the files that you wish to add then click Insert
Alternate Way
- Open up BBEdit
- Create a new Text Document (Command N)
- In the Finder drag and drop the text files into the BBEdit window
Using the Command Line
Another solution is to use the Cat Unix command in Terminal. Here's a sample of what that would look like:
cat access.log.* >> website.log