Archiving tool for Bilibili based on bilix
pip install biliarchiver
biliarchiver --help
Follow these steps to start archiving:
- Initialize a new workspace in current working directory:
biliarchiver init
- Provide cookies and tokens following instructions:
biliarchiver auth
- Download videos from BiliBili:
biliarchiver down --bvids BVXXXXXXXXX
- This command also accepts a list of BVIDs or path to a file. Details can be found in
biliarchiver down --help
.
Dumping entire channels into Community Video is abusive and may get your account locked. Talk to the Internet Archive admins first before doing large uploads; it's better to ask for guidence or help first than run afoul of the rules.
Please use poetry to install dependencies:
poetry install
Build English locale if necessary. Refer to the last section for details.
poetry run biliarchiver --help
Debug using another workspace:
poetry --directory /path/to/workspace run biliarchiver --help
poetry run ruff check .
To generate and build locales, you need a GNU gettext compatible toolchain. You can install mingw
and use sh
to enter a bash shell on Windows.
Generate or update biliarchiver.pot
:
find biliarchiver/ -name '*.py' | xargs xgettext -d base -o biliarchiver/locales/biliarchiver.pot
Add a new language:
msginit -i biliarchiver/locales/biliarchiver.pot -o en.po -l en
Update a language:
msgmerge -U biliarchiver/locales/en/LC_MESSAGES/biliarchiver.po biliarchiver/locales/biliarchiver.pot
(Important) Build a language:
msgfmt biliarchiver/locales/en/LC_MESSAGES/biliarchiver.po -o biliarchiver/locales/en/LC_MESSAGES/biliarchiver.mo