{"thread":{"id":"47567","subject":"git-p4 + watchman - watching the p4 repo?","startedAt":"2018-01-08T17:15:31Z","lastAt":"2018-01-08T17:42:17Z","messageCount":2,"participants":["Luke Diamand","Ben Peart"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"336155","messageId":"CAE5ih79t8N969E-8qm9JMNZZo6qvRqw6GA=b6UTHskB-ozt7Fg@mail.gmail.com","threadId":"47567","inReplyTo":null,"subject":"git-p4 + watchman - watching the p4 repo?","fromName":"Luke Diamand","fromEmail":"luke@diamand.org","sentAt":"2018-01-08T17:15:25Z","receivedAt":"2018-01-08T17:15:31Z","isPatch":false,"sender":{"key":"luke@diamand.org","avatar":"https://avatars.githubusercontent.com/u/5330967?v=4"},"body":"Hi!\n\nI could be wrong about this, but I when I tried mixing watchman with\ngit-p4, I found that on \"git p4 submit\" it ended up watching the p4\nrepo, which seems a bit pointless (and was also very slow).\n\n$ [create git-p4 clone of some p4 repo]\n$ : >bar\n$ git add bar && git commit -m 'adding bar'\n$ git p4 submit --origin HEAD^ --shelve\nPerforce checkout for depot path //depot/ located at /tmp/p4/cli/\nSynchronizing p4 checkout...\n... - file(s) up-to-date.\nApplying 4ce4057 change\n//depot/bar#1 - opened for edit\nAdding '/tmp/p4/cli' to watchman's watch list.\n\nIs there any way to stop it doing this?\n\nThanks!\nLuke\n"},{"id":"336158","messageId":"DM5PR2101MB0902FE564628A5604AB860F9F4130@DM5PR2101MB0902.namprd21.prod.outlook.com","threadId":"47567","inReplyTo":"CAE5ih79t8N969E-8qm9JMNZZo6qvRqw6GA=b6UTHskB-ozt7Fg@mail.gmail.com","subject":"RE: git-p4 + watchman - watching the p4 repo?","fromName":"Ben Peart","fromEmail":"ben.peart@microsoft.com","sentAt":"2018-01-08T17:42:06Z","receivedAt":"2018-01-08T17:42:17Z","isPatch":false,"sender":{"key":"benpeart@microsoft.com","avatar":"https://avatars.githubusercontent.com/u/15252029?v=4"},"body":"I haven't used perforce so am unfamiliar with any behaviors specific to that but the logic to have git automatically tell watchman to start watching repos is just a convenience feature.  Feel free to remove/disable/modify it in the fsmonitor-watchman integration script:\n\n\tif ($retry > 0 and $o->{error} and $o->{error} =~ m/unable to resolve root .* directory (.*) is not watched/) {\n\t\tprint STDERR \"Adding '$git_work_tree' to watchman's watch list.\\n\";\n\t\t$retry--;\n\t\tqx/watchman watch \"$git_work_tree\"/;\n\nBen\n\n> -----Original Message-----\n> From: Luke Diamand [mailto:luke@diamand.org]\n> Sent: Monday, January 8, 2018 12:15 PM\n> To: Git Users <git@vger.kernel.org>\n> Cc: Alex Vandiver <alexmv@dropbox.com>; Ben Peart\n> <Ben.Peart@microsoft.com>\n> Subject: git-p4 + watchman - watching the p4 repo?\n> \n> Hi!\n> \n> I could be wrong about this, but I when I tried mixing watchman with git-p4, I\n> found that on \"git p4 submit\" it ended up watching the p4 repo, which seems\n> a bit pointless (and was also very slow).\n> \n> $ [create git-p4 clone of some p4 repo]\n> $ : >bar\n> $ git add bar && git commit -m 'adding bar'\n> $ git p4 submit --origin HEAD^ --shelve\n> Perforce checkout for depot path //depot/ located at /tmp/p4/cli/\n> Synchronizing p4 checkout...\n> ... - file(s) up-to-date.\n> Applying 4ce4057 change\n> //depot/bar#1 - opened for edit\n> Adding '/tmp/p4/cli' to watchman's watch list.\n> \n> Is there any way to stop it doing this?\n> \n> Thanks!\n> Luke\n"}]}