Giter Site home page Giter Site logo

Comments (6)

Tarrasch avatar Tarrasch commented on August 23, 2024

I have for some time thought on something just like this. I like the names antigen-snapshot and antigen-restore. I definitely think this is a good next step for antigen, since what I like with pathogen (compared to vundle) is that with pathogen+gitmodules you commit your submodule hashes when you know that it will work because you have used it. I haven't tried Vundle yet, but afaik it's like antigen now. You don't have information about the versions of the submodules across your dotfiles repository.

An idea I had was to let antigen-snapshot not take any arguments. It could create something like the .gitmodules file and let antigen-snapshot read from that standard file and checkout those revisions. But there is really no "default" place to put such a file (I guess everyone doesn't have a dotfiles repository). So yea, I guess one should do as you said, that is to just provide the desired snapshot path as argument. Then the user can then decide weather they wanna check it in or just put it in a gist somewhere.

So yea, I agree with everything you said, it makes sense and I like the naming.

from antigen.

GUIpsp avatar GUIpsp commented on August 23, 2024

Easiest way to do this IMHO is a newline separated pair of the location of origin and the hash

from antigen.

sharat87 avatar sharat87 commented on August 23, 2024

@Tarrasch, you're right. Let's seeif Vundle ends up taking inspiration from antigen on this feature, that would be so much win :)

I haven't thought of the arguments to those commands, but come to think of it, what you say sounds good.

@GUIpsp, true. That is how the antigen-revert command is currently implemented. It should be fairly easy to bring that in to these commands.

from antigen.

Tarrasch avatar Tarrasch commented on August 23, 2024

As for antigen-revert, I think antigen-revert could be a one-liner provided we have antigen-{snapshot,restore}. We can let antigen-update just internally do a antigen-snapshot on some file and let antigen-revert be an alias for antigen-restore that-file. Would this work? If so it could save us some code duplication.

from antigen.

sharat87 avatar sharat87 commented on August 23, 2024

Yep, that's how it will be done.

from antigen.

sharat87 avatar sharat87 commented on August 23, 2024

Okay, I just pushed a quick implementation and I got to go now. There is also a test which is very lacking, IMO. Please check it out and let me know what you think.

I still have to change antigen-update and antigen-revert to use these new commands.

from antigen.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.