[or-cvs] [metrics-db/master 1/2] Prevent config file from being overwritten by Git.

karsten at torproject.org karsten at torproject.org
Mon Dec 27 15:09:45 UTC 2010


Author: Karsten Loesing <karsten.loesing at gmx.net>
Date: Mon, 27 Dec 2010 16:06:43 +0100
Subject: Prevent config file from being overwritten by Git.
Commit: 629e855fa014b3009e51a561b515e7d24d3fe9ea

---
 .gitignore      |    3 +
 build.xml       |    1 +
 config          |  120 -------------------------------------------------------
 config.template |  120 +++++++++++++++++++++++++++++++++++++++++++++++++++++++
 4 files changed, 124 insertions(+), 120 deletions(-)
 delete mode 100644 config
 create mode 100644 config.template

diff --git a/.gitignore b/.gitignore
index 7d307b1..4cf88fc 100644
--- a/.gitignore
+++ b/.gitignore
@@ -41,3 +41,6 @@ website/consensus-health*.html
 # Temporary directory for generating web archive
 dist/
 
+# Possibly modified config file
+config
+
diff --git a/build.xml b/build.xml
index cf440ab..187787d 100644
--- a/build.xml
+++ b/build.xml
@@ -22,6 +22,7 @@
 <!--ERNIE-specific targets -->
   <target name="init">
     <mkdir dir="${classes}"/>
+    <copy file="config.template" tofile="config"/>
   </target>
   <target name="compile" depends="init"> 
     <javac srcdir="${sources}"
diff --git a/config b/config
deleted file mode 100644
index c275c87..0000000
--- a/config
+++ /dev/null
@@ -1,120 +0,0 @@
-#### Data sources ####
-#
-## Read cached-* files from a local Tor data directory
-#ImportCachedRelayDescriptors 0
-#
-## Relative path to Tor data directory to read cached-* files from (can be
-## specified multiple times)
-#CachedRelayDescriptorsDirectory cacheddesc/
-#
-## Import directory archives from disk, if available
-#ImportDirectoryArchives 0
-#
-## Relative path to directory to import directory archives from
-#DirectoryArchivesDirectory archives/
-#
-## Keep a history of imported directory archive files to know which files
-## have been imported before. This history can be useful when importing
-## from a changing source to avoid importing descriptors over and over
-## again, but it can be confusing to users who don't know about it.
-#KeepDirectoryArchiveImportHistory 0
-#
-## Download relay descriptors from directory authorities, if required
-#DownloadRelayDescriptors 0
-#
-## Comma separated list of directory authority addresses (IP[:port]) to
-## download missing relay descriptors from
-#DownloadFromDirectoryAuthorities 86.59.21.38,194.109.206.212,212.112.245.170
-#
-## Import sanitized bridges from disk, if available
-#ImportSanitizedBridges 0
-#
-## Relative path to directory to import sanitized bridges from
-#SanitizedBridgesDirectory bridges/
-#
-## Keep a history of imported sanitized bridge descriptors. This history
-## can be useful when importing from a changing data source to avoid
-## importing descriptors more than once, but it can be confusing to users
-## who don't know about it.
-#KeepSanitizedBridgesImportHistory 0
-#
-## Import bridge snapshots from disk, if available
-#ImportBridgeSnapshots 0
-#
-## Relative path to directory to import bridge descriptor snapshots from
-#BridgeSnapshotsDirectory bridge-directories/
-#
-## Import local Maxmind GeoIP databases
-#ImportGeoIPDatabases 0
-#
-## Relative path to directory to import GeoIP databases from
-#GeoIPDatabasesDirectory geoipdb/
-#
-## Download (commercial) Maxmind GeoIP database for sanitizing bridge
-## descriptors
-#DownloadGeoIPDatabase 0
-#
-## Maxmind license key for downloading commercial GeoIP databases
-#MaxmindLicenseKey NA
-#
-## Import torperf data, if available, and write stats to disk
-#ImportWriteTorperfStats 0
-#
-## Relative path to directory to import torperf results from
-#TorperfDirectory torperf/
-#
-## Download and process GetTor stats
-#DownloadProcessGetTorStats 0
-#
-## URL to download GetTor stats from
-#GetTorStatsURL http://gettor.torproject.org:8080/~gettor/gettor_stats.txt
-#
-## Download exit list and store it to disk
-#DownloadExitList 0
-#
-#### Data sinks ####
-#
-## Write directory archives to disk
-#WriteDirectoryArchives 0
-#
-## Relative path to directory to write directory archives to
-#DirectoryArchivesOutputDirectory directory-archive/
-#
-## Write relay descriptors to a database for later evaluation
-#WriteRelayDescriptorDatabase 0
-#
-## Write aggregate statistics (bridges and bridge users per day, directory
-## clients per day, torperf results, packages requested from GetTor, etc.)
-## to database for later evaluation
-#WriteAggregateStatsDatabase 0
-#
-## JDBC string for relay descriptor database
-#RelayDescriptorDatabaseJDBC jdbc:postgresql://localhost/tordir?user=ernie&password=password
-#
-## Write relay descriptors to raw text files for importing them into a
-## database using PostgreSQL's \copy command
-#WriteRelayDescriptorsRawFiles 0
-#
-## Relative path to directory to write raw text files; note that existing
-## files will be overwritten!
-#RelayDescriptorRawFilesDirectory pg-import/
-#
-## Write statistics about the current consensus and votes to the
-## website
-#WriteConsensusHealth 0
-#
-## Write sanitized bridges to disk
-#WriteSanitizedBridges 0
-#
-## Relative path to directory to write sanitized bridges to
-#SanitizedBridgesWriteDirectory sanitized-bridges/
-#
-## Write consensus stats to disk
-#WriteConsensusStats 0
-#
-## Write dirreq stats to disk
-#WriteDirreqStats 0
-#
-## Write bridge stats to disk
-#WriteBridgeStats 0
-
diff --git a/config.template b/config.template
new file mode 100644
index 0000000..c275c87
--- /dev/null
+++ b/config.template
@@ -0,0 +1,120 @@
+#### Data sources ####
+#
+## Read cached-* files from a local Tor data directory
+#ImportCachedRelayDescriptors 0
+#
+## Relative path to Tor data directory to read cached-* files from (can be
+## specified multiple times)
+#CachedRelayDescriptorsDirectory cacheddesc/
+#
+## Import directory archives from disk, if available
+#ImportDirectoryArchives 0
+#
+## Relative path to directory to import directory archives from
+#DirectoryArchivesDirectory archives/
+#
+## Keep a history of imported directory archive files to know which files
+## have been imported before. This history can be useful when importing
+## from a changing source to avoid importing descriptors over and over
+## again, but it can be confusing to users who don't know about it.
+#KeepDirectoryArchiveImportHistory 0
+#
+## Download relay descriptors from directory authorities, if required
+#DownloadRelayDescriptors 0
+#
+## Comma separated list of directory authority addresses (IP[:port]) to
+## download missing relay descriptors from
+#DownloadFromDirectoryAuthorities 86.59.21.38,194.109.206.212,212.112.245.170
+#
+## Import sanitized bridges from disk, if available
+#ImportSanitizedBridges 0
+#
+## Relative path to directory to import sanitized bridges from
+#SanitizedBridgesDirectory bridges/
+#
+## Keep a history of imported sanitized bridge descriptors. This history
+## can be useful when importing from a changing data source to avoid
+## importing descriptors more than once, but it can be confusing to users
+## who don't know about it.
+#KeepSanitizedBridgesImportHistory 0
+#
+## Import bridge snapshots from disk, if available
+#ImportBridgeSnapshots 0
+#
+## Relative path to directory to import bridge descriptor snapshots from
+#BridgeSnapshotsDirectory bridge-directories/
+#
+## Import local Maxmind GeoIP databases
+#ImportGeoIPDatabases 0
+#
+## Relative path to directory to import GeoIP databases from
+#GeoIPDatabasesDirectory geoipdb/
+#
+## Download (commercial) Maxmind GeoIP database for sanitizing bridge
+## descriptors
+#DownloadGeoIPDatabase 0
+#
+## Maxmind license key for downloading commercial GeoIP databases
+#MaxmindLicenseKey NA
+#
+## Import torperf data, if available, and write stats to disk
+#ImportWriteTorperfStats 0
+#
+## Relative path to directory to import torperf results from
+#TorperfDirectory torperf/
+#
+## Download and process GetTor stats
+#DownloadProcessGetTorStats 0
+#
+## URL to download GetTor stats from
+#GetTorStatsURL http://gettor.torproject.org:8080/~gettor/gettor_stats.txt
+#
+## Download exit list and store it to disk
+#DownloadExitList 0
+#
+#### Data sinks ####
+#
+## Write directory archives to disk
+#WriteDirectoryArchives 0
+#
+## Relative path to directory to write directory archives to
+#DirectoryArchivesOutputDirectory directory-archive/
+#
+## Write relay descriptors to a database for later evaluation
+#WriteRelayDescriptorDatabase 0
+#
+## Write aggregate statistics (bridges and bridge users per day, directory
+## clients per day, torperf results, packages requested from GetTor, etc.)
+## to database for later evaluation
+#WriteAggregateStatsDatabase 0
+#
+## JDBC string for relay descriptor database
+#RelayDescriptorDatabaseJDBC jdbc:postgresql://localhost/tordir?user=ernie&password=password
+#
+## Write relay descriptors to raw text files for importing them into a
+## database using PostgreSQL's \copy command
+#WriteRelayDescriptorsRawFiles 0
+#
+## Relative path to directory to write raw text files; note that existing
+## files will be overwritten!
+#RelayDescriptorRawFilesDirectory pg-import/
+#
+## Write statistics about the current consensus and votes to the
+## website
+#WriteConsensusHealth 0
+#
+## Write sanitized bridges to disk
+#WriteSanitizedBridges 0
+#
+## Relative path to directory to write sanitized bridges to
+#SanitizedBridgesWriteDirectory sanitized-bridges/
+#
+## Write consensus stats to disk
+#WriteConsensusStats 0
+#
+## Write dirreq stats to disk
+#WriteDirreqStats 0
+#
+## Write bridge stats to disk
+#WriteBridgeStats 0
+
-- 
1.7.1




More information about the tor-commits mailing list