Skip to content
Simple rsync profiler
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.
LICENSE Initial commit Aug 11, 2019 Add Table of Contents and security related notes Aug 30, 2019
rpf Fix problematic syntax A && B || C Sep 29, 2019


Simple rsync profiler

Table of Contents


With rpf you can create, save and run different rsync configurations via named profiles.


Let's create new profile named 'backup' by typing rpf -c backup

Assume that our user name is user.

rpf creates following directories:

  • /home/user/.rpf
  • /home/user/.rpf/shared - here you can place config files shared by multiple profiles
  • /home/user/.rpf/profiles - here all profiles are saved as subdirectories

So rpf created for us /home/user/.rpf/profiles/backup, that contains files conf and excluded.

conf defines rsync configuration:

# rsync config template
# Write each rsync option on separate line. For option details see man rsync.
# Empty lines and lines starting with # are ignored. Dynamic references
# (e.g. using command substitution) are not supported.
# Config files shared between different profiles should be saved in
# /home/user/.rpf/shared
# Example configuration:
# exclude all files that match pattern in:
# perform trial run, make no changes
# source, e.g.
# destination, e.g.

Now we can edit, add or remove rsync options as needed.

In exclude we can define paths or patterns of files and directories we want to exclude from transfer. To exclude Trash and Downloads add following lines:

- /home/user/.local/share/Trash
- /home/user/Downloads

Or transfer only Documents and Projects and exclude everything else:

+ /home/user/Documents
+ /home/user/Projects
- **

For subtler pattern configuration, see man rsync, section FILTER RULES, or google for tutorials.

When we are ready, we can start rsync transfer by typing rpf backup

That's it.

For additional rpf options see rpf --help.


rpf is not secure against code injection in conf file. Any additional code (e.g. ; ./run_evil_script) is also executed. Therefore, protect your .rpf/ config directory from malicious users by appropriate permissions. Moreover, exploitation of this behavior can also lead to unexpected side effects.

You can’t perform that action at this time.