]> git.cworth.org Git - tar/blob - gnu/backupfile.h
upstream: Fix extraction of device nodes.
[tar] / gnu / backupfile.h
1 /* -*- buffer-read-only: t -*- vi: set ro: */
2 /* DO NOT EDIT! GENERATED AUTOMATICALLY! */
3 /* backupfile.h -- declarations for making Emacs style backup file names
4
5    Copyright (C) 1990-1992, 1997-1999, 2003-2004, 2009-2010 Free Software
6    Foundation, Inc.
7
8    This program is free software: you can redistribute it and/or modify
9    it under the terms of the GNU General Public License as published by
10    the Free Software Foundation; either version 3 of the License, or
11    (at your option) any later version.
12
13    This program is distributed in the hope that it will be useful,
14    but WITHOUT ANY WARRANTY; without even the implied warranty of
15    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16    GNU General Public License for more details.
17
18    You should have received a copy of the GNU General Public License
19    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
20
21 #ifndef BACKUPFILE_H_
22 # define BACKUPFILE_H_
23
24 # ifdef __cplusplus
25 extern "C" {
26 # endif
27
28
29 /* When to make backup files. */
30 enum backup_type
31 {
32   /* Never make backups. */
33   no_backups,
34
35   /* Make simple backups of every file. */
36   simple_backups,
37
38   /* Make numbered backups of files that already have numbered backups,
39      and simple backups of the others. */
40   numbered_existing_backups,
41
42   /* Make numbered backups of every file. */
43   numbered_backups
44 };
45
46 # define VALID_BACKUP_TYPE(Type)        \
47   ((unsigned int) (Type) <= numbered_backups)
48
49 extern char const *simple_backup_suffix;
50
51 char *find_backup_file_name (char const *, enum backup_type);
52 enum backup_type get_version (char const *context, char const *arg);
53 enum backup_type xget_version (char const *context, char const *arg);
54 void addext (char *, char const *, int);
55
56
57 # ifdef __cplusplus
58 }
59 # endif
60
61 #endif /* ! BACKUPFILE_H_ */