diff options
author | Joel Rosdahl <joel@rosdahl.net> | 2016-07-19 15:20:34 +0200 |
---|---|---|
committer | Joel Rosdahl <joel@rosdahl.net> | 2016-07-19 15:42:56 +0200 |
commit | 1f0fc314cca166944cb232695d4fb432dd1de7c9 (patch) | |
tree | dbc3a4bae902d160e7606e2d07354a8316b5a436 | |
parent | 504c8798af6ee38f928b179dc3c37accae920e8c (diff) | |
download | miniircd-1f0fc314cca166944cb232695d4fb432dd1de7c9.tar.gz miniircd-1f0fc314cca166944cb232695d4fb432dd1de7c9.zip |
Rename --statedir to --state-dir for consistency
-rwxr-xr-x | miniircd | 12 | ||||
-rw-r--r-- | test.py | 2 |
2 files changed, 7 insertions, 7 deletions
@@ -48,9 +48,9 @@ class Channel(object): self.members = set() self._topic = "" self._key = None - if self.server.statedir: + if self.server.state_dir: self._state_path = "%s/%s" % ( - self.server.statedir, + self.server.state_dir, name.replace("_", "__").replace("/", "_")) self._read_state() else: @@ -643,7 +643,7 @@ class Server(object): self.log_dir = options.log_dir self.chroot = options.chroot self.setuid = options.setuid - self.statedir = options.statedir + self.state_dir = options.state_dir self.log_file = options.log_file self.log_maxbytes = options.log_maxsize * 1024 * 1024 self.log_count = options.log_count @@ -673,8 +673,8 @@ class Server(object): self.nicknames = {} # irc_lower(Nickname) --> Client instance. if self.log_dir: create_directory(self.log_dir) - if self.statedir: - create_directory(self.statedir) + if self.state_dir: + create_directory(self.state_dir) def make_pid_file(self, filename): try: @@ -941,7 +941,7 @@ def main(argv): help="listen to ports X (a list separated by comma or whitespace);" " default: 6667 or 6697 if SSL is enabled") op.add_option( - "--statedir", + "--state-dir", metavar="X", help="save persistent channel state (topic, key) in directory X") op.add_option( @@ -27,7 +27,7 @@ class ServerFixture(object): "--ports=%d" % SERVER_PORT, ] if persistent: - arguments.append("--statedir=%s" % self.state_dir) + arguments.append("--state-dir=%s" % self.state_dir) os.execv("./miniircd", arguments) # Parent. self.child_pid = pid |