[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

[PATCH] Remove .svn/README.txt

From: Philip Martin <philip_at_codematters.co.uk>
Date: 2004-11-05 00:02:57 CET

Can anyone see any compatability problems?

Log:

Don't create .svn/README.txt in working copies.

* subversion/libsvn_wc/wc.h
  (SVN_WC__ADM_README): Remove unused #define.

* subversion/libsvn_wc/adm_files.c
  (init_adm_file): Remove unsed function.
  (init_adm): Don't create README.txt.

Patch:

Index: subversion/libsvn_wc/wc.h
===================================================================
--- subversion/libsvn_wc/wc.h (revision 11751)
+++ subversion/libsvn_wc/wc.h (working copy)
@@ -105,7 +105,6 @@
 
 /** The files within the administrative subdir. **/
 #define SVN_WC__ADM_FORMAT "format"
-#define SVN_WC__ADM_README "README.txt"
 #define SVN_WC__ADM_ENTRIES "entries"
 #define SVN_WC__ADM_LOCK "lock"
 #define SVN_WC__ADM_TMP "tmp"
Index: subversion/libsvn_wc/adm_files.c
===================================================================
--- subversion/libsvn_wc/adm_files.c (revision 11751)
+++ subversion/libsvn_wc/adm_files.c (working copy)
@@ -928,27 +928,7 @@
 }
 
 
-/* Init an adm file with some contents.
- Don't call this until a tmp area exists in adm. */
 static svn_error_t *
-init_adm_file (const char *path,
- const char *thing,
- const char *contents,
- apr_pool_t *pool)
-{
- apr_file_t *f = NULL;
-
- SVN_ERR (svn_wc__open_adm_file (&f, path, thing,
- APR_WRITE | APR_CREATE, pool));
- SVN_ERR (svn_io_file_write_full (f, contents,
- strlen (contents), NULL, pool));
- SVN_ERR (svn_wc__close_adm_file (f, path, thing, 1, pool));
-
- return SVN_NO_ERROR;
-}
-
-
-static svn_error_t *
 init_adm_tmp_area (svn_wc_adm_access_t *adm_access,
                    apr_pool_t *pool)
 {
@@ -995,18 +975,11 @@
   /* Default perms */
   apr_fileperms_t perms = APR_OS_DEFAULT;
 
- /* Initial contents for certain adm files. */
- const char *readme_contents =
- "This is a Subversion working copy administrative directory."
- APR_EOL_STR
- "Visit http://subversion.tigris.org/ for more information."
- APR_EOL_STR;
-
   /* First, make an empty administrative area. */
   make_empty_adm (path, pool);
 
   /* Lock it immediately. Theoretically, no compliant wc library
- would ever consider this an adm area until a README file were
+ would ever consider this an adm area until a version file were
      present... but locking it is still appropriately paranoid. */
   SVN_ERR (svn_wc__adm_pre_open (&adm_access, path, pool));
 
@@ -1046,9 +1019,6 @@
                                    APR_UREAD | APR_GREAD | APR_WREAD,
                                    0, pool));
 
- /* SVN_WC__ADM_README */
- SVN_ERR (init_adm_file (path, SVN_WC__ADM_README, readme_contents, pool));
-
   /* THIS FILE MUST BE CREATED LAST:
      After this exists, the dir is considered complete. */
   SVN_ERR (svn_io_write_version_file

-- 
Philip Martin
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Fri Nov 5 00:03:23 2004

This is an archived mail posted to the Subversion Dev mailing list.