Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WIP: Config parser #11

Merged
merged 2 commits into from
May 15, 2021
Merged

Conversation

daanbreur
Copy link
Collaborator

This PR contains commits that make functions

  • importVafConfig public:
    • return type VafConfigStructure
  • parseWordlist private:
    • parameter type JsonNode
    • returns type VafWordlist
  • parseVafConfig public:
    • parameter type JsonNode
    • returns type VafConfigStructure

Return Type *VafConfigStructure*
Contains *parseWordlist* and *parseVafConfig* function

parseWordlist <private>:
 - parameter type *JsonNode*
 - returns type *VafWordlist*

 parseVafConfig <public>:
 - parameter type *JsonNode*
 - returns type *VafConfigStructure*
@daanbreur
Copy link
Collaborator Author

This pr is in relation with #7 and #8

src/config/importVafConfig.nim Show resolved Hide resolved

import VafConfigStructure

var homeDir: string = os.getHomeDir()
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

maybe put this in a separate file? it gets quite repetitive

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What should we put in a seperate file?

Copy link
Owner

@d4rckh d4rckh May 14, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What should we put in a seperate file?

not sure, maybe a constants.nim in src/

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good Idea! 👍 Lets refactor later tho

@daanbreur daanbreur marked this pull request as ready for review May 14, 2021 14:07
@d4rckh d4rckh merged commit 28c7504 into d4rckh:vaf-configfile May 15, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants