ow do I use the rsync tool to copy only the hidden files and directory (such as ~/.ssh/, ~/.foo, and so on) from /home/jobs directory to the /mnt/usb directory under Unix like operating system?
I see many examples and man pages on how to do operations like search-and-replace using sed. But, I want to match a given string or a regular pattern expression and display on the screen. How do I print lines with matching pattern using sed command only under Unix like operating systems?
How do I find out my DNS server IP address assiged my my ISP under Unix or Linux operating system using command prompt? How do I find preferred dns server under Debian / Ubuntu / Fedora Linux desktop system?
ow do I mirror files from remote FTP server using lftp command? How do put the entire directory from a local disk to a remote FTP server (reverse mirror) using lftp command under Linux and Unix like operating systems?
I need to copy files from my second hard disk. This hard disk formatted with UFS 2 file system. How do I mount UFS 2 file system created by FreeBSD on my Debian Linux 6 based system?
I know wget command can resume downloads. H>ow do I resume partially transferred files using rsync command line under Unix like operating systems?
I‘m writing a bash wrapper script that will pass arguments to the command. I need to find out the last argument if I call the wrapper as follows:
./wrapper -a -b –longarg=foo thisfilename.txt
./wrapper -a -b thisfilename.txt
./wrapper -a –next=true thisfilename.txt
=> $@ is all of them.
=> $0 is script name.
=> $1 is first arg.
I want thisfilename.txt stored in a shell variable called $last. How do I find the last argument passed to a shell script written in bash or ksh under Unix like operating systems?