GithubHelp home page GithubHelp logo

simmeringratchet / ldsgeneralconferencedownloader Goto Github PK

View Code? Open in Web Editor NEW
13.0 1.0 5.0 8 KB

A script to download General Conference talks for offline listneing

License: MIT License

Python 100.00%
lds general playlist language mp3 m3u8 conference talk

ldsgeneralconferencedownloader's Introduction

LDSGeneralConferenceDownloader

A script to download General Conference talks for offline listening.

Who is this for?

This script is ideal for:

  • Going on long journeys without reliable internet connection,
  • Full-time missionaries who want to listen to conference talks during study time,
  • Anyone who wishes to study from the conference talks but doesn't have a reliable internet connection.

What it can do?

This script will allow you to download the LDS General Conference talks in mp3 form that are available at https://www.lds.org/general-conference. It will create playlists as *.m3u files to allow you to play an entire session. It will also create playlists for speakers and topcs. This will not only work with the default English versions, but also for every other language for which audio files are available. Currently, hundreds of talks are available in many languages, going back as far as 1971 for some.

How does it work?

It will programmatically navigate the lds.org website, downloading and organising every talk of interest to you. Everything will be saved to a local folder of your choice. Load these files onto a memory stick for your car, or into your favourite media player.

What do I need to do to run this script?

  1. Install Python 3. If you don't have Python installed on your system, then follow the instructions here to install it: https://www.python.org/downloads/
  2. The script needs some external library functionality. Using the terminal, navigate to this folder, then run the command: pip install -r requirements.txt
  3. The script is run as follows: python gen_conf_downloader.py
  4. There are a number of optional arguments that my be added to the above command (run python gen_conf_downloader.py -h for full list):
Argument Values Meaning
-h or --help List all arguments and exit
-l or -lang 3-letter language code Indicates which language version is to be downloaded. See https://www.lds.org/languages for full list. Click on the language you want, then take note of the 3-letter code in the address bar. i.e. https://www.lds.org/?lang=*spa*
-s or -start Year as 4 digit number First year of conference to download. Defaults to 1971. Note: not all historic sessions are available in all languages
-e or -end Year as 4 digit number Last year to download (defaults to present year).
-d or -dest folder relative to here. i.e. ./conference Destination folder to output files to. Defaults to output
-n or -nocleanup Leaves temporary files after process completion.
-v or -verbose Provides detailed activity logging instead of progress bars.

Note: Depending upon how many years worth of conferences you ask it to download, it may take some time!

What does it generate?

It will generate a folder structure as follows in your destination folder:

output
└───eng
    └───Conferences
    │   └───2018
    │   │   └───4
    │   │   │   Priesthood Session.m3u
    │   │   │   Saturday Morning Session.m3u
    │   │   │   ...
    │   │   └───10
    │   │       ...
    │   └───2017
    │       ...
    └───MP3
    │   └───2018
    │   │   └───4
    │   │   │   └───Priesthood Session
    │   │   │   │   Am I a Child of God? (Brian K. Taylor).mp3
    │   │   │   │   Even as Christ Forgives You, So Also Do Ye (Larry J. Echo Hawk).mp3
    │   │   │   │   ...
    │   │   │   └───Saturday Morning Session
    │   │   │   │   ...
    │   │   └───10
    │   └───2017
    │       ...
    └───Speakers
    │   D. Todd Christofferson(1, 13m).m3u
    |   Dallin H. Oaks(3, 45m).m3u
    |   ...
    └───Topics
        Adversity(3, 44m).m3u
        Atonement(6, 1h4m).m3u
        ...

The playlists for the Topics and Speakers include in parenthesis the number of talks and the total duration.

ldsgeneralconferencedownloader's People

Contributors

sam-niconi avatar simmeringratchet avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

ldsgeneralconferencedownloader's Issues

Line 36 syntax error.

Unfortunately, I know nothing about Python, but I get this when trying to run your tool:

python gen_conf_downloader.py
File "gen_conf_downloader.py", line 36
ALL_CONFERENCES_URL = f'{LDS_ORG_URL}/general-conference/conferences'
^
SyntaxError: invalid syntax

Though the caret is at the single quote at the end of the line.

Still works in 2022?

I was using the latest branch (LDSGeneralConferenceDownloader-0732128c4ca9a4498469336ecf70a9e931706fe4/), and I am coming across a problem where from what I can tell nothing is being pulled and so is causing an out of range error. See below:

% python3.9 gen_conf_downloader.py -start 2021 -end 2022 -dest ../talks/ -nocleanup -verbose -lang eng
https://www.churchofjesuschrist.org/languages
https://www.churchofjesuschrist.org/general-conference/conferences?lang=eng
Traceback (most recent call last):
File "[source_dir]/gen_conf_downloader.py", line 435, in
get_all_conferences_seasons(cli_args)
File "[source_dir]/gen_conf_downloader.py", line 72, in get_all_conferences_seasons
remove_generated_files(args, playlist_dirs)
File "[source_dir]/gen_conf_downloader.py", line 200, in remove_generated_files
shutil.rmtree(f'{get_output_dir(args)}/{playlist_dirs[CONFERENCES_DIR]}', ignore_errors=True)
IndexError: list index out of range

Does this script still work with the current website?

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.