From: David Stainton Date: Tue, 23 Jun 2015 08:01:48 +0000 (-0700) Subject: Append magic-folder config options to tahoe.cfg X-Git-Url: https://git.rkrishnan.org/maximilian?a=commitdiff_plain;h=ac419b6bb717e82f1e5a58140aac70be5d9dda61;p=tahoe-lafs%2Ftahoe-lafs.git Append magic-folder config options to tahoe.cfg --- diff --git a/src/allmydata/scripts/magic_folder_cli.py b/src/allmydata/scripts/magic_folder_cli.py index 99cb7115..58f13e15 100644 --- a/src/allmydata/scripts/magic_folder_cli.py +++ b/src/allmydata/scripts/magic_folder_cli.py @@ -128,8 +128,10 @@ def join(options): collective_readcap_file = os.path.join(options["node-directory"], "private/collective_dircap") fileutil.write(collective_readcap_file, magic_readonly_cap) - # Edit the client's tahoe.cfg to set [magic_folder] enabled = True and [magic_folder] local.directory = LOCAL_DIR. - # ... + c = open(os.path.join(options["node-directory"], "tahoe.cfg"), "a") + c.write("[magic_folder]\nenabled = True\n[magic_folder]\nlocal.directory = %s\n" % (options.local_dir,)) + c.close() + class MagicFolderCommand(BaseOptions): subCommands = [