Skip to content

smolijar/zcraper

Repository files navigation

Zcraper

forthebadge forthebadge forthebadge forthebadge

Build Status Coverage Maintainability Vulnerabilities Dependency Status Dev Dependency Status

Songbook scraper for zpevniky.com

You have a songbook to manage and you keep it in a RTE document? If so, and you did any changes through the course of times, you are either dying, or an advanced wizard.

If its the former visit zpevniky.com, create a songbook and come back here. With the little bit of JS you will be able to do marvels. Moreover, automate the whole process! If you change a song, just rerun zcraper, theme your songbook in any way your heart desires.

If its the latter, then get out of here, you magical thing, you are destined to do great things! ✨

Quickstart

  1. Run example
npm install
npm build
npm start
  1. Program output html files in the root dir. Open them in browser and print or save as PDF via a print dialog.
  2. Modify the example in src/index.ts and roll!
import { compose, loadCss, renameSongs, saveSongbook, sortSongs } from './lib/helpers';
import { songbookService } from './lib/songbookService';

(async () => {
    // get songbook via id
    const songbook = await songbookService.getSongbook(171);
    // implicit settings
    saveSongbook(songbook);
})();
saveSongbook(songbook, {
    // my transformations
    fns: [songbook => { /* Do your magic if you want */ return songbook; }],
    // output filename
    filename: 'custom-output.html',
    // custom serialization function
    serialize: JSON.stringify,
});

License

This project is licensed under MIT.

About

Songbook scraper for zpevniky.com

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages