Which of the following commands creates an archive file work.tar from the contents of the directory ./work/?
Which of the following commands creates an archive file work.tar from the contents of the directory ./work/?
To create an archive file using the `tar` command in Linux, the correct syntax involves using the `-c` option to create the archive and the `-f` option to specify the name of the archive file. Therefore, `tar -cf work.tar ./work/` will correctly create an archive named work.tar from the contents of the ./work/ directory.
B is the right answer but it's wrongly typed tar -cf work.tar ./work/
for some reason the platform is replacing dashes with four single quotes
http://www.linfo.org/tar.html
tar -cf work.tar ./work/ # Create work.tar from files in ./work/ .
the answer is B. tar -cf work.tar ./work/. The -cf option combines -c option which is to create the tar file, and -f which is the option to name the file. "To create an archive with tar, use the ‘-c’ (“create”) option, and specify the name of the archive file to create with the ‘-f’ option. It’s common practice to use a name with a ‘.tar’ extension, such as ‘my-backup.tar’." https://training.linuxfoundation.org/blog/how-to-create-and-manage-archive-files-in-linux/
B. tar ג€"cf work.tar ./work/
B is the Answer.
ג€" What does it mean, someone could explain to me?
it is a typo from -cf