Skip to content

common command line parser#1100

Draft
375gnu wants to merge 5 commits into
masterfrom
command-line-parser
Draft

common command line parser#1100
375gnu wants to merge 5 commits into
masterfrom
command-line-parser

Conversation

@375gnu

@375gnu 375gnu commented Jul 4, 2021

Copy link
Copy Markdown
Collaborator

@levinli303 what do you think about this? my attempt is to remove copy-pasted command line parsing and keep the its common part to celestiacore. it's tested with qt/gtk/win. not finished yet. i want to hear your feedback. it also contains some tiny unrelated changes i will file them as separate prs.

@levinli303

Copy link
Copy Markdown
Collaborator

since my frontends do not really accept command line arguments, im fine with the changes as long as we still expose interfaces to load from specific .cfg and extra dirs.

Also I wonder if we can move away from current directory to load from, would it make sense for all files to be loaded according to an absolute path?

@375gnu

375gnu commented Jul 8, 2021

Copy link
Copy Markdown
Collaborator Author

Also I wonder if we can move away from current directory to load from, would it make sense for all files to be loaded according to an absolute path?

We can use absolute paths in many (or even all) places of celestia.cfg. Or do you mean something else?

@levinli303

Copy link
Copy Markdown
Collaborator

I'm saying now (on my frontends), I need to call chdir (or similar APIs) to change working directory so the relative path in data files in cfg can be correctly loaded. is it possible to avoid it. (maybe store a value of the root path for relative paths to load from?)

@375gnu

375gnu commented Jul 9, 2021

Copy link
Copy Markdown
Collaborator Author

chdir approach is much simpler, in this pr i want to move it to CelestiaCore

@375gnu
375gnu marked this pull request as draft July 17, 2021 13:44
@375gnu
375gnu force-pushed the master branch 2 times, most recently from 690ab56 to 2f8f3b0 Compare May 15, 2023 19:57
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.

2 participants