how to use terminal to zip a file code example Example: zip folder terminal zip -r mynewfilename.zip foldertozip/