Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Message from discussion Can I doesn't use popt alias file for rsync, while use the alias function in-line/in-place with the rsync command?
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Hongyi Zhao  
View profile  
 More options Oct 28 2012, 10:13 pm
Newsgroups: comp.unix.shell
From: Hongyi Zhao <hongyi.z...@gmail.com>
Date: Mon, 29 Oct 2012 02:13:09 +0000 (UTC)
Local: Sun, Oct 28 2012 10:13 pm
Subject: Re: Can I doesn't use popt alias file for rsync, while use the alias function in-line/in-place with the rsync command?

On Sun, 28 Oct 2012 21:26:07 +0000, Ben Bacarisse wrote:
> Part of the problem is what you seem to be asking -- how to avoid using
> the .popt file -- seems to be too simple to be the actual problem.  If
> that's all you want to do, just add the arguments that -Z aliases
> directly.

Let me give more detailed of my topic:

In my case, I first use the /home/werner/.popt file to define the alias -
Z as follows:

$ cat /home/werner/.popt  
rsync alias -Z --no-p --no-g --chmod=ugo=rwX

Then I run rsync with the alias -Z like this:

$ rsync -avZ --temp-dir=/tmp /media/cdrom/pool/ /home/werner/Desktop/111/

Now, suppose I want to do some more complicated job including the above
codes in it, I think it's a more easier way first define the
alias_varialbe in the script then invoke it by using rsync command in the
same script.  I just want to know how to do the above things like this
way.

BTW, as you have pointed that, we can simply invoke the rsync like for my
purpose:

rsync -av --no-p --no-g --chmod=ugo=rwX --temp-dir=/tmp /media/cdrom/
pool/ /home/werner/Desktop/111/

But for a more complicated case, say, I want to do server different rsync
jobs with different alias options in one script, according to the
described method here, I must define all of the  alias options in  /home/
werner/.popt, in this way, I must remember all of the these definitions
in mind when I want to invoke them.  While if I can define these alias
options in-place of the shell script which use all of these alias
options, I think it will be more convenient to use.

Regards


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.