przemoc / metastore

Store and restore metadata from a filesystem.
http://software.przemoc.net/#metastore
GNU General Public License v2.0
171 stars 31 forks source link

Branches switching support #3

Closed vtolstov closed 8 years ago

vtolstov commented 10 years ago

currenct metastore hooks does not support branches that contains different dirs/files perms.

przemoc commented 10 years ago

@vtolstov, could you elaborate?

git doesn't offer pre/post checkout hooks or something like that, so it's up to the user to save (and commit or stash) or restore perms before or after swtiching branches. Or you're talking about something else?

vtolstov commented 10 years ago

I have .metastore file that contains some data. After i switch branch and commit something, metastore modify file. And after switch back - i have many new dirs, perm, files for example.

przemoc commented 10 years ago

Firstly, I was wrong and there is post-checkout hook. Sorry for writing previous comment without checking it carefully. Secondly, I haven't used metastore within git yet to be honest (as I was simply using it outside of any VCS; that's why my first need to patch it came), so I'll have to ask you to provide more details (1). Then I'll be able to accept your request and create proper enhancement issues.

What's your metastore setup within repository? Your metastore's metadata file is committed there, right? What hooks related to metastore are you already using while working within repository?

(1) I'll check myself too how it is used within git and try to improve metastore for git usage, I even created topic issue for that already


Mind that metastore alone has no notion of branches and I dare to say it shouldn't ever have it, but we can try to improve side tooling (like examplary git hooks) and add features necessary to handle common cases unsupported without them.

przemoc commented 8 years ago

I believe that the matter has been fixed for some time (to the extent that git hooks allow). Just now I only improved it further a little (in 95921e7ad884). Please check a warning in the comments of pre-commit hook, though.

@vtolstov Please check how the hook scripts work for you now.