home *** CD-ROM | disk | FTP | other *** search
/ Amiga MA Magazine 1998 #6 / amigamamagazinepolishissue1998.iso / coders / indent / backup.h < prev    next >
C/C++ Source or Header  |  2001-07-31  |  1KB  |  51 lines

  1.  
  2. /* backup.h -- declarations for making Emacs style backup file names
  3.    Copyright (C) 1992 Free Software Foundation, Inc.
  4.  
  5.    This program is free software; you can redistribute it and/or modify
  6.    it without restriction.
  7.  
  8.    This program is distributed in the hope that it will be useful,
  9.    but WITHOUT ANY WARRANTY; without even the implied warranty of
  10.    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  */
  11.  
  12.  
  13. /* When to make backup files.  Analagous to 'version-control'
  14.    in Emacs. */
  15. enum backup_mode
  16. {
  17.   /* Uninitialized or indeterminate value */
  18.   unknown,
  19.  
  20.   /* Never make backups. */
  21.   none,
  22.  
  23.   /* Make simple backups of every file. */
  24.   simple,
  25.  
  26.   /* Make numbered backups of files that already have numbered backups,
  27.      and simple backups of the others. */
  28.   numbered_existing,
  29.  
  30.   /* Make numbered backups of every file. */
  31.   numbered
  32. };
  33.  
  34. struct version_control_values
  35. {
  36.   enum backup_mode value;
  37.   char *name;
  38. };
  39.  
  40. /* Determine the value of `version_control' by looking in the
  41.    environment variable "VERSION_CONTROL".  Defaults to
  42.    numbered_existing. */
  43. extern enum backup_mode version_control_value ();
  44.  
  45. /* Initialize information used in determining backup filenames. */
  46. extern void initialize_backups ();
  47.  
  48. /* Make a backup copy of FILE, taking into account version-control.
  49.    See the description at the beginning of the file for details. */
  50. extern void make_backup ();
  51.