Last active
April 12, 2020 15:15
-
-
Save scripting/aa50ae77b8929bcad55c8b7125a6f3ba to your computer and use it in GitHub Desktop.
Psuedocode for how I'd like zip archivng to work. It gives me full JS to decide if a file belongs or doesn't.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const zip = require ("davezip"); | |
| const fs = require ("fs"); | |
| const theArchiveFile = zip.createArchive ('outlines.zip"); | |
| fs.fileloop ("/users/bullmancuso/publicfiles/", function (err, f) { //I made up fs.fileloop, it would be nice ;-) | |
| if (f.hasExtension (".opml")) { | |
| zip.addToArchive (f, theArchiveFile); | |
| } | |
| }); | |
| zip.closeArchive (theArchiveFile); |
Author
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I've gotten the sample code for the archiver package to work locally. So I'm on the road.