# # # add_dir "tests/commit_use_workspace_keydir" # # add_file "tests/commit_use_workspace_keydir/__driver__.lua" # content [3b080116b803ded67686ffc6b16d21920156d249] # # patch "NEWS" # from [7ea4147ccff843083f444258f81173c0897ed4a8] # to [596e4d3365125094563bbe3b4bdc8a82b635ef62] # # patch "monotone.texi" # from [dc35fb0596a751174a3013ab03b8abe7b60ccb11] # to [a198d13bb3365b7d67591144799f5330377aacc6] # # patch "netxx_pipe.cc" # from [fd09aa9fe81d1f7d17c214b3489e23371e9aa056] # to [5898486124bb2b60d9a5481d615703e0b02212dd] # # patch "tests/clone_-b_no_dir/__driver__.lua" # from [24877f2ff4e2e8df6051bb60fa8a373dbeac2b29] # to [6261c4ed37c1a5e10ea7e27aacdf722287ec8682] # # patch "tests/clone_creates__MTN_log/__driver__.lua" # from [da936653810379282e5456c38552448f100186eb] # to [b55d72be85979711d50af45907e134f18428a405] # # patch "tests/clone_creates_right__MTN_options/__driver__.lua" # from [ff16d67dfa4f7dadc2be5fa8e1c15e397aaca498] # to [99090f6f660254a145fd2d892282bca37a723361] # # patch "tests/clone_validates_target_directory/__driver__.lua" # from [7c920d5ae0b54336f15a81000fb5eaffa039a7cd] # to [ca4db9a9677e80a1015f129f8cbaf4face246a58] # # patch "tests/clone_warning_with_multiple_heads/__driver__.lua" # from [6b20959fea5d1d7b0e3d570149aac6466aa84beb] # to [7185de1271934179a95cf11aa12b561404323c61] # # patch "tests/imp_test_filesync_confdir/__driver__.lua" # from [a0c260d405c38adf1a0db939f8b3b0549e442528] # to [b39e74627fec7a846eeffceddd9fd37436c8a5f7] # # patch "tests/netsync_over_pipes/__driver__.lua" # from [c7ff47e60f1a2891a1b58071b208d98e21bddc29] # to [1a8939dac67aa519eaa449512bc617e42c5f1620] # # patch "work.cc" # from [84dc74091e3318424da00b914dd904d3e884ce5f] # to [8036882e43a0c0dc71798cea7d5931b17808a84c] # ============================================================ --- tests/commit_use_workspace_keydir/__driver__.lua 3b080116b803ded67686ffc6b16d21920156d249 +++ tests/commit_use_workspace_keydir/__driver__.lua 3b080116b803ded67686ffc6b16d21920156d249 @@ -0,0 +1,27 @@ +-- Test that commit uses keydir from _MTN/options +-- It didn't in 0.39 + +mtn_setup() + +-- adapted from lua-testsuite.lua 'mtn' +function mtn_default_keydir(...) + -- Return mtn command string that uses default keydir. Specifing + -- --confdir also sets --keydir, so don't specify either. + if monotone_path == nil then + monotone_path = os.getenv("mtn") + if monotone_path == nil then + err("'mtn' environment variable not set") + end + end + return {monotone_path, "--norc", "--root=" .. test.root, "--db", "test.db", + "--rcfile", test.root .. "/test_hooks.lua", + "address@hidden", "--debug", unpack(arg)} +end + +addfile("randomfile", "random stuff") + +-- this should find the right key in the keydir specified by _MTN/options +commit("testbranch", "blah-blah", mtn_default_keydir) + +-- end of file + ============================================================ --- NEWS 7ea4147ccff843083f444258f81173c0897ed4a8 +++ NEWS 596e4d3365125094563bbe3b4bdc8a82b635ef62 @@ -13,8 +13,13 @@ using --depth. The simple fix for anyone using --depth is to add 1 to the values they are using. + - Document that ssh: and file: sync transports are not supported on + native Win32. + Bugs fixed + - `commit' now uses keydir specified in _MTN/options + New features Internal @@ -51,7 +56,7 @@ Mon Feb 25 15:55:36 UTC 2008 If you use the '--with-system-pcre' configure switch, it will insist on at least this version. - - "emacs" has been removed from the list of dumb terminal types; + - "emacs" has been removed from the list of dumb terminal types; tickers should now default to --ticker=count with emacs terminals - extensive section on merge conflicts and ways to resolve them @@ -65,13 +70,13 @@ Mon Feb 25 15:55:36 UTC 2008 - the path handling of 'mtn revert' was improved and fixed two bugs: now a restricted revert on a node "dir1/file1" reverts only the content changes in "file1", but leaves renames of any of its - ancestor nodes untouched; furthermore, if "dir0/" was renamed to + ancestor nodes untouched; furthermore, if "dir0/" was renamed to "dir1" and "dir1/file1" was dropped, mtn now re-creates file1 at the proper place ("dir1/") and leaves no missing files around because of the non-existing "dir0/". - a few changes needed to build with gcc 4.3. - + New features - 'automate drop_db_variables' which drops one database variable @@ -85,9 +90,9 @@ Mon Feb 25 15:55:36 UTC 2008 directories. The typical case of listing files that need attention now runs at least four times faster. - - 'automate get_current_revision' which outputs the revision text of + - 'automate get_current_revision' which outputs the revision text of changes in the current workspace - + Wed Dec 12 21:21:15 UTC 2007 0.38 release. ============================================================ --- monotone.texi dc35fb0596a751174a3013ab03b8abe7b60ccb11 +++ monotone.texi a198d13bb3365b7d67591144799f5330377aacc6 @@ -2656,6 +2656,9 @@ @section Other Transports @code{file:@var{/path/to/db.mtn}}, to synchronize between local databases. @end enumerate address@hidden:} and @code{file:} are currently not supported on the native +Win32 platform; they are supported on Cygwin and all other platforms. + In the case of SSH URIs, the @command{ssh} program must be in your command execution path, either @var{$PATH} on Unix-like systems or @var{%PATH%} on Windows systems. Monotone will execute @command{ssh} @@ -5430,6 +5433,16 @@ @section Key and Cert Trust increases the risk of a key compromise on your local computer. Be careful using this hook. +The public key is stored in the database; the public and private keys +are stored in the keystore. This allows copying the database without +copying the private key. + +The location of the keystore is specified by the @option{--keydir} +option; it defaults to the value stored in @file{_MTN/options} for +commands executed in a workspace, or to +the system default (@file{~/.monotone/keys} on Unix and Cygwin, address@hidden/monotone/keys} on native Win32). + @item mtn dropkey @var{keyid} This command drops the public and/or private key. If both exist, both ============================================================ --- netxx_pipe.cc fd09aa9fe81d1f7d17c214b3489e23371e9aa056 +++ netxx_pipe.cc 5898486124bb2b60d9a5481d615703e0b02212dd @@ -46,6 +46,10 @@ Netxx::PipeStream::PipeStream(int _readf #endif { #ifdef WIN32 + E(0, F("this transport not supported on native Win32; use Cygwin")); + + // keeping code in case someone wants to try fixing it + if (_setmode(_readfd, _O_BINARY) == -1) L(FL("failed to set input file descriptor to binary")); @@ -174,6 +178,10 @@ Netxx::PipeStream::PipeStream (const str #ifdef WIN32 + E(0, F("this transport not supported on native Win32; use Cygwin")); + + // keeping code in case someone wants to try fixing it + // In order to use nonblocking i/o on windows, you must use named // pipes and overlapped i/o. There is no other way, alas. @@ -488,12 +496,12 @@ Netxx::PipeCompatibleProbe::add(StreamBa void Netxx::PipeCompatibleProbe::add(StreamBase const &sb, ready_type rt) { - // FIXME: This is *still* an unfortunate way of performing a - // downcast, though slightly less awful than the old way, which - // involved throwing an exception. + // FIXME: This is *still* an unfortunate way of performing a + // downcast, though slightly less awful than the old way, which + // involved throwing an exception. // // Perhaps we should twiddle the caller-visible API. - + StreamBase const *sbp = &sb; PipeStream const *psp = dynamic_cast(sbp); if (psp) @@ -544,6 +552,8 @@ Netxx::PipeCompatibleProbe::add(const St #ifdef BUILD_UNIT_TESTS #include "unit_tests.hh" +#ifndef WIN32 + UNIT_TEST(pipe, simple_pipe) { try { @@ -610,6 +620,7 @@ catch (informative_failure &e) } } #endif +#endif // Local Variables: // mode: C++ ============================================================ --- tests/clone_-b_no_dir/__driver__.lua 24877f2ff4e2e8df6051bb60fa8a373dbeac2b29 +++ tests/clone_-b_no_dir/__driver__.lua 6261c4ed37c1a5e10ea7e27aacdf722287ec8682 @@ -1,3 +1,5 @@ +skip_if(ostype == "Windows") -- file: not supported on native Win32 + mtn_setup() addfile("foo", "blah blah") ============================================================ --- tests/clone_creates__MTN_log/__driver__.lua da936653810379282e5456c38552448f100186eb +++ tests/clone_creates__MTN_log/__driver__.lua b55d72be85979711d50af45907e134f18428a405 @@ -1,3 +1,4 @@ +skip_if(ostype == "Windows") -- file: not supported on native Win32 mtn_setup() ============================================================ --- tests/clone_creates_right__MTN_options/__driver__.lua ff16d67dfa4f7dadc2be5fa8e1c15e397aaca498 +++ tests/clone_creates_right__MTN_options/__driver__.lua 99090f6f660254a145fd2d892282bca37a723361 @@ -1,3 +1,4 @@ +skip_if(ostype == "Windows") -- file: not supported on native Win32 mtn_setup() ============================================================ --- tests/clone_validates_target_directory/__driver__.lua 7c920d5ae0b54336f15a81000fb5eaffa039a7cd +++ tests/clone_validates_target_directory/__driver__.lua ca4db9a9677e80a1015f129f8cbaf4face246a58 @@ -1,3 +1,4 @@ +skip_if(ostype == "Windows") -- file: not supported on native Win32 mtn_setup() ============================================================ --- tests/clone_warning_with_multiple_heads/__driver__.lua 6b20959fea5d1d7b0e3d570149aac6466aa84beb +++ tests/clone_warning_with_multiple_heads/__driver__.lua 7185de1271934179a95cf11aa12b561404323c61 @@ -1,3 +1,4 @@ +skip_if(ostype == "Windows") -- file: not supported on native Win32 mtn_setup() ============================================================ --- tests/imp_test_filesync_confdir/__driver__.lua a0c260d405c38adf1a0db939f8b3b0549e442528 +++ tests/imp_test_filesync_confdir/__driver__.lua b39e74627fec7a846eeffceddd9fd37436c8a5f7 @@ -1,4 +1,7 @@ -- Test that --confdir gets passed properly on file: sync + +skip_if(ostype == "Windows") -- file: not supported on native Win32 + mtn_setup() copy("test.db", "test2.db") ============================================================ --- tests/netsync_over_pipes/__driver__.lua c7ff47e60f1a2891a1b58071b208d98e21bddc29 +++ tests/netsync_over_pipes/__driver__.lua 1a8939dac67aa519eaa449512bc617e42c5f1620 @@ -1,3 +1,4 @@ +skip_if(ostype == "Windows") -- file: not supported on native Win32 mtn_setup() ============================================================ --- work.cc 84dc74091e3318424da00b914dd904d3e884ce5f +++ work.cc 8036882e43a0c0dc71798cea7d5931b17808a84c @@ -378,7 +378,7 @@ read_options_file(any_path const & optsp string opt, val; parser.sym(opt); parser.str(val); - + if (opt == "database") database_option = system_path(val); else if (opt == "branch") @@ -451,7 +451,6 @@ workspace::get_ws_options(options & opts if (!opts.key_dir_given && !opts.conf_dir_given) { - I(opts.key_dir.empty()); opts.key_dir = keydir_option; }