chrisbenincasa / berglas-node

Node library for decrypting Berglas secrets
MIT License
7 stars 5 forks source link

Parallell processing #4

Closed ivank closed 4 years ago

ivank commented 4 years ago

Hey awesome library!

Works quite well, however I substitute calls for me can take quite a while to resolve, if you have a a bunch of env variables to substitute.

It would be quite easy to

Right now the substitute function is O(N) and for most use cases it should be more like O(1).

I'll be more than happy to do a PR, but it might be a substantial change and wanted to ask what you think about it first :)

What do you think?

chrisbenincasa commented 4 years ago

Great idea! I just merged your pull request - much appreciated! This should be available in version 1.0.3 now.