<p dir="ltr">I just use syncthing. There is probably a race where pass and syncthing try to commit the change but with syncthing's delay to wait for more changes it works quite well in practice. </p>
<div class="gmail_quote">On Jan 2, 2016 08:38, "Asheesh Laroia" <<a href="mailto:asheesh@sandstorm.io">asheesh@sandstorm.io</a>> wrote:<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi all,<div><br></div><div>I've been a happy user of "pass" for a few years.</div><div><br></div><div>I just set up a private git repository that I now use "pass git push" to synchronize with.</div><div><br></div><div>One thing I'm concerned about is that I might "pass generate" and then forget to "pass git push". Particularly, I'm used to having monitoring and/or automation for essential systems. So I'm curious - has anyone set up automatic "git push" upon running "pass generate"?</div><div><br></div><div>I know I could write some of my own scripts as git hooks, but it seems to me it's a little nontrivial, so in the interest of saving time and discovering existing best practices, I'm interested in finding out if others have done something already.</div><div><br></div><div>I'm interested in hearing about all approaches people have set up, even ones they're not super thrilled with!</div><div><br></div><div>Here's my first thought on how I'd do it (though happy to hear other ideas too)</div><div><br></div><div>- On "pass generate" (aka on creating a new local commit), do a "pass git push", and if it fails, declare that it's OK that it failed</div><div><br></div><div>- On "pass" (password copying), if origin/master is behind local master, print a warning saying that I should "pass git push". (This handles failure from the previous item.)</div><div><br></div><div>- On "pass" (password copying), if origin/master and master are in sync but origin/master hasn't been fetched in (say) 7 days, then print a warning saying "You should probably run 'pass git pull'." Detect the last fetch of origin/master by looking at the filesystem mtime of .git/FETCH_HEAD, e.g. on my system:</div><div><br></div><div><div>$ ls -l .git/FETCH_HEAD </div><div>-rw-r--r-- 1 paulproteus paulproteus 113 Jan 1 23:32 .git/FETCH_HEAD</div></div><div><br></div><div><br></div><div>Curious what others have done!<br></div><div><br></div><div>Cheers,</div><div><br></div><div>Asheesh.</div></div>
<br>_______________________________________________<br>
Password-Store mailing list<br>
<a href="mailto:Password-Store@lists.zx2c4.com">Password-Store@lists.zx2c4.com</a><br>
<a href="http://lists.zx2c4.com/mailman/listinfo/password-store" rel="noreferrer" target="_blank">http://lists.zx2c4.com/mailman/listinfo/password-store</a><br>
<br></blockquote></div>