github.com/keybase/client/go@v0.0.0-20240309051027-028f7c731f8b/kbfs/libfs/constants.go (about)

     1  // Copyright 2016 Keybase Inc. All rights reserved.
     2  // Use of this source code is governed by a BSD
     3  // license that can be found in the LICENSE file.
     4  
     5  package libfs
     6  
     7  // MetricsFileName is the name of the KBFS metrics file -- it can be
     8  // reached from any KBFS directory.
     9  const MetricsFileName = ".kbfs_metrics"
    10  
    11  // ReclaimQuotaFileName is the name of the KBFS quota-reclaiming file
    12  // -- it can be reached anywhere within a top-level folder.
    13  const ReclaimQuotaFileName = ".kbfs_reclaim_quota"
    14  
    15  // RekeyFileName is the name of the KBFS rekeying file -- it can be
    16  // reached anywhere within a top-level folder.
    17  const RekeyFileName = ".kbfs_rekey"
    18  
    19  // StatusFileName is the name of the KBFS status file -- it can be reached
    20  // anywhere within a top-level folder or inside the Keybase root
    21  const StatusFileName = ".kbfs_status"
    22  
    23  // SyncFromServerFileName is the name of the KBFS sync-from-server
    24  // file -- it can be reached anywhere within a top-level folder.
    25  const SyncFromServerFileName = ".kbfs_sync_from_server"
    26  
    27  // UnstageFileName is the name of the KBFS unstaging file -- it can be
    28  // reached anywhere within a top-level folder.
    29  const UnstageFileName = ".kbfs_unstage"
    30  
    31  // DisableUpdatesFileName is the name of the KBFS update-disabling
    32  // file -- it can be reached anywhere within a top-level folder.
    33  const DisableUpdatesFileName = ".kbfs_disable_updates"
    34  
    35  // EnableUpdatesFileName is the name of the KBFS update-enabling
    36  // file -- it can be reached anywhere within a top-level folder.
    37  const EnableUpdatesFileName = ".kbfs_enable_updates"
    38  
    39  // ResetCachesFileName is the name of the KBFS unstaging file.
    40  const ResetCachesFileName = ".kbfs_reset_caches"
    41  
    42  // EnableJournalFileName is the name of the journal-enabling file. It
    43  // can be reached anywhere within a top-level folder.
    44  const EnableJournalFileName = ".kbfs_enable_journal"
    45  
    46  // FlushJournalFileName is the name of the journal-flushing file. It
    47  // can be reached anywhere within a top-level folder.
    48  const FlushJournalFileName = ".kbfs_flush_journal"
    49  
    50  // PauseJournalBackgroundWorkFileName is the name of the file that
    51  // pauses the background work of a journal. It can be reached anywhere
    52  // within a top-level folder.
    53  const PauseJournalBackgroundWorkFileName = ".kbfs_pause_journal_background_work"
    54  
    55  // ResumeJournalBackgroundWorkFileName is the name of the file that
    56  // resumes the background work of a journal. It can be reached
    57  // anywhere within a top-level folder.
    58  const ResumeJournalBackgroundWorkFileName = ".kbfs_resume_journal_background_work"
    59  
    60  // DisableJournalFileName is the name of the journal-disabling
    61  // file. It can be reached anywhere within a top-level folder.
    62  const DisableJournalFileName = ".kbfs_disable_journal"
    63  
    64  // EnableAutoJournalsFileName is the name of the KBFS-wide
    65  // auto-journal-enabling file.  It's accessible anywhere outside a TLF.
    66  const EnableAutoJournalsFileName = ".kbfs_enable_auto_journals"
    67  
    68  // DisableAutoJournalsFileName is the name of the KBFS-wide
    69  // auto-journal-disabling file.  It's accessible anywhere outside a
    70  // TLF.
    71  const DisableAutoJournalsFileName = ".kbfs_disable_auto_journals"
    72  
    73  // EnableBlockPrefetchingFileName is the name of the KBFS-wide
    74  // prefetching-enabling file.  It's accessible anywhere outside a TLF.
    75  const EnableBlockPrefetchingFileName = ".kbfs_enable_block_prefetching"
    76  
    77  // DisableBlockPrefetchingFileName is the name of the KBFS-wide
    78  // prefetching-disabling file.  It's accessible anywhere outside a TLF.
    79  const DisableBlockPrefetchingFileName = ".kbfs_disable_block_prefetching"
    80  
    81  // EnableDebugServerFileName is the name of the file to turn on the
    82  // debug HTTP server. It's accessible anywhere outside a TLF.
    83  const EnableDebugServerFileName = ".kbfs_enable_debug_server"
    84  
    85  // DisableDebugServerFileName is the name of the file to turn on the
    86  // debug HTTP server. It's accessible anywhere outside a TLF.
    87  const DisableDebugServerFileName = ".kbfs_disable_debug_server"
    88  
    89  // EditHistoryName is the name of the KBFS TLF edit history file --
    90  // it can be reached anywhere within a top-level folder.
    91  const EditHistoryName = ".kbfs_edit_history"
    92  
    93  // UpdateHistoryFileName is the name of the KBFS update history -- it
    94  // can be reached anywhere within a top-level folder.
    95  const UpdateHistoryFileName = ".kbfs_update_history"
    96  
    97  // FileInfoPrefix is the prefix of the per-file metadata files.
    98  const FileInfoPrefix = ".kbfs_fileinfo_"
    99  
   100  // EnableSyncFileName is the name of the file to enable the sync cache for a
   101  // TLF. It can be reached anywhere within a TLF.
   102  const EnableSyncFileName = ".kbfs_enable_sync"
   103  
   104  // DisableSyncFileName is the name of the file to disable the sync cache for a
   105  // TLF. It can be reached anywhere within a TLF.
   106  const DisableSyncFileName = ".kbfs_disable_sync"
   107  
   108  // ArchivedRevDirPrefix is the prefix to the directory at the root of a
   109  // TLF that exposes a version of that TLF at the specified revision.
   110  const ArchivedRevDirPrefix = ".kbfs_archived_rev="
   111  
   112  // ArchivedTimeLinkPrefix is the prefix to the symlink at the root of a
   113  // TLF that links to a version of that TLF at the specified time.
   114  const ArchivedTimeLinkPrefix = ".kbfs_archived_time="
   115  
   116  // ArchivedRelTimeFilePrefix is the prefix to the file at the root of
   117  // a TLF that contains the directory name of an archived revision
   118  // described by the given relative time.
   119  const ArchivedRelTimeFilePrefix = ".kbfs_archived_reltime="
   120  
   121  // OpenFileCountFileName is the name of the file that contains the
   122  // number of KBFS files and directories currently being held open by
   123  // the operating system.
   124  const OpenFileCountFileName = ".kbfs_open_file_count"
   125  
   126  // DirBlockPrefix is the prefix to a directory within a TLF, that will
   127  // direct KBFS to open that specific block as that directory.  Useful
   128  // for recovering data of a subdirectory when the all the root blocks
   129  // are missing or corrupt for some reason.  The format for what comes
   130  // after the prefix is: id.keyGen.dataVer.creatorUID.directType
   131  //
   132  // Note that if this is used for a directory that is already live in
   133  // the current TLF, it will make that existing directory read-only.
   134  const DirBlockPrefix = ".kbfs_dirblock_"
   135  
   136  // ProfileListDirName is the name of the KBFS profile directory -- it
   137  // can be reached from any KBFS directory.
   138  const ProfileListDirName = ".kbfs_profiles"
   139  
   140  // ErrorFileName is the name of the virtual file in KBFS that should
   141  // contain the last reported error(s).
   142  var ErrorFileName = ".kbfs_error"