Giter Site home page Giter Site logo

Comments (4)

nielsmaerten avatar nielsmaerten commented on July 23, 2024

Hey rauhasto

It's an interesting topic. On the one hand you're right about this being a bit of a feature creep.
ynab-buddy is supposed to be a generic tool, so adding an exception for 1 bank does go against that philosophy. (This is how projects like YNAP end up having to maintain 100+ different formats.)

On the other hand... if this is supposed to be a generic tool, then it should work with any (csv) format, no matter how weird the bank makes it. 🤔

💡 With that in mind, here's a (possible) solution I came up with:
ynab-buddy could be extended using a hooks system.

Here's what that could look like:

  • Alongside the config file in ~/ynab-buddy/config.yaml, there would be a javascript file: hooks.js
  • That file would contain several functions that each get called at certain points in the process of parsing a file, extracting transactions, and uploading them to YNAB.
  • By adding your own code, you could "hook into" any part of the process, and modify the behavior. In your case: you could delete any line containing the text "Varaus", after ynab-buddy has finished parsing the file, but before it starts converting lines into transactions.

Of course this approach is assuming you're comfortable writing a bit of javascript code. (Or maybe, have ChatGPT do it?)
This is still in the 'idea' phase, so I'd love to hear your thoughts!

from ynab-buddy.

rauhasto avatar rauhasto commented on July 23, 2024

Hi,

And thanks for help!

This would be a good idea! For now I've made a batch script that deletes these problematic lines from the input csv and then calls ynab-buddy. It seems to work pretty ok. However your solution does sound better.

By the way have you planned to add cleared/not cleared support for transactions? I actually meant that when I incorrectly used term "reservation". Those Nordea "Varaus" lines are transactions that have not yet been cleared. It does seem that the api supports importing them but I'm not so sure about the csv uploader.

from ynab-buddy.

nielsmaerten avatar nielsmaerten commented on July 23, 2024

Hi again @rauhasto , hope you're doing well
Good news: the Hooks 🪝 feature is now in Beta!

This should not only allow you to remove certain transactions from your CSV files, but also mark transactions as 'uncleared' before they're uploaded to your budget.

I've already started using a hook of my own to clean up the "memo" field in my own CSV files. (My bank loves putting random junk there)

If you have some time to give Hooks a try, I'd love to get your feedback.
Just let me know if you need some help getting set up, or if you run into any issues. After all, it's still a beta 🏗️😉

from ynab-buddy.

rauhasto avatar rauhasto commented on July 23, 2024

Great! I'll have a look as soon as possible. This would likely be a good alternative for my current messy batch script (why on earth did I make it with batch? 😅).

Big thanks for developing this tool further and listening to ideas! 💪

from ynab-buddy.

Related Issues (16)

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.