Closed Grommers00 closed 5 years ago
@Grommers00 Good work so far 👍
Here's what I did:
There's a problem though; I can only give absolute paths as the argument. I want to be able to pass relative paths too. We can merge this after that is taken care of.
Ah - Yeah, I ran into that issue at the beginning, and I found it would work in the .budget-cli folder, as a relative. I'm open to suggestions - but that was the CWD when I checked.
@Grommers00 Before reading the file, you have to temporarily change the CWD as the directory where the user is currently running the budget insert
command.
I don't know how to do it, but it shouldn't be difficult.
@Grommers00 Nevermind, I just fixed it. It turns out I forgot to restore the CWD after building the sheet service.
Closes #12
I created a new command for parsing a file. It then goes through the loop of a file and will sequentially add them to your spreadsheets. It takes into consideration for comments in the code as well, so you as long as you # the beginning of the line in the text file it would be able to do this.
To use this the command:
budget insert \PATH\TO\FILE