Git Product home page Git Product logo

Comments (5)

odarbelaeze avatar odarbelaeze commented on July 29, 2024

@richard-evans what do you think of using a pre-existent format such as yaml, json or INI files.

from vampire.

richard-evans avatar richard-evans commented on July 29, 2024

The format of the input files is fine as far as I am concerned (they are meant to be read and written by humans), but the processing code for them is unwieldy (3500+ lines of code in a single file). Eventually these will probably be refactored into an i/o module incorporating some new features such as a command line manual.

from vampire.

odarbelaeze avatar odarbelaeze commented on July 29, 2024

Separating the input into a separated module would make it a little bit more manageable for sure, specially you break it down to smaller files. In order to get it better, maybe we can make an approach with an Option class, so that all options get parsed automatically, a register for all the options, so there should be just one file listing all of them, and maybe a command pattern, through which the side effects of options and flags can be specified using simple functions.

from vampire.

richard-evans avatar richard-evans commented on July 29, 2024

An option class is an interesting idea. I had a look at this but everything gets a little crazy with templates and I kind of got stuck with the complexity of the solution (elegant for the coder but horrendous for the designer!). At the moment I have stuck with the current code design but with new options moved to an interface file in each submodule of vampire, which keeps things tidier for now. However, I would really like to include a command line help and also have a searchable list of options, which would require some central options class-type solution. Maybe the best way is to have distributed command registration but central parsing. Some more thought is required here I think...

from vampire.

odarbelaeze avatar odarbelaeze commented on July 29, 2024

Learning from somewhere else might help as well, I think this problem is common to several packages out there, maybe we should look for some on github see what they do.

from vampire.

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.