Description

Jottacloud Command-line Client supports ignoring file and folders by placing special ignore files in the folder structure you are backing up. 

There are two methods to exclude files and folders:

  • Global excludes 
  • Folder specific excludes

Global excludes

You can use jotta-cli to load global exclude files that are applied to all folders. Simply create a file with the exclude pattern you want, and load it using the ignores set command.

jotta-cli ignores set 'path/to/ignorefile' 

To view the global exclude patterns on your system. Use the ignores get command:

jotta-cli ignores get 

This will print all the global exclude rules. Example from Mac OS X:

---------------------------------------------
#
# ---- START OSX DEFAULTS ----
#
# The patterns listed in this file are the hardcoded
# and imutable ignore rules. These will always be respected
# by the client regardless of any other specified rules

### OSX ###
.DS_Store
.AppleDouble
.LSOverride
Icon\r

# Files that might appear in the root of a volume
.DocumentRevisions-V100
.fseventsd
.Spotlight-V100
.TemporaryItems
.Trashes
.VolumeIcon.icns
.com.apple.timemachine.donotpresent

# Directories potentially created on remote AFP share
.AppleDB
.AppleDesktop
Network Trash Folder
Temporary Items
.apdisk
#
# ---- END DEFAULTS ----
#

Folder specific excludes

You can add folder specific exclude files to individual folders you back up. Simply add a special file in the folder of your choice. This file is called .jottaignore 

A .jottaignore file specifies intentionally untracked files that Jottacloud CLI should ignore. .jottaignore  is similar to .gitignore

A key difference between .jottaignore and .gitignore  is that changes made to .jottaignore  files will affect already backed up files and folders. That means if you add an exclude pattern to exclude an already backed up file or folder, the file or folder will be deleted from your backup on Jottacloud.

Each line in a .jottaignore  file specifies a pattern.

Note: .jottaignore  files are only supported by the Jottacloud Command-line Client. The Jottacloud Desktop Client do not support .jottaignore files.

Pattern format

The pattern format of .jottaignore  is the same as .gitignore . Please see documentation for .gitignore.

Examples

### WordPress ###
*.log
wp-config.php
wp-content/advanced-cache.php
wp-content/backup-db/
wp-content/backups/
wp-content/blogs.dir/
wp-content/cache/
wp-content/upgrade/
wp-content/uploads/
wp-content/wp-cache-config.php
wp-content/plugins/hello.php

/.htaccess
/license.txt
/readme.html
/sitemap.xml
/sitemap.xml.gz

Gitignore.io is a useful tool for creating .gitignore files. This tool can also be used to create .jottaignore  files.

Did this answer your question?