#!/bin/bash DIR=/home/mx for i in $(ls $DIR); do IN=$DIR/$i OUT=/home/backup/mx/${i}_$(date -I).tar.bz2 echo "$IN > $OUT" tar -cjf $OUT $IN done
Do you like this page? Then support it. Please click the AD below and visit the sponsor. Thank you!