Package: pferd
PFERDProgramm zumFlotten,EinfachenRunterladen vonDateienOther resources:Config file formatChangelogDevelopment GuideInstallationDirect downloadBinaries for Linux, Windows and Mac can be downloaded directly from thelatest release.With pipEnsure you have at least Python 3.9 installed. Run the following command to
install PFERD or upgrade it to the latest version:$ pip install --upgrade git+https://github.com/Garmelon/PFERD@latestThe use ofvenvis recommended.With package managersUnofficial packages are available for:AURbrewconda-forgenixpkgsPyPiSee also PFERD'srepology page.Basic usagePFERD can be run directly from the command line with no config file. Runpferd -hto get an overview of available commands and options. Runpferd <command> -hto see which options a command has.For example, you can download your personal desktop from the KIT ILIAS like
this:$ pferd kit-ilias-web desktop <output_directory>Also, you can download most ILIAS pages directly like this:$ pferd kit-ilias-web <url> <output_directory>However, the CLI only lets you download a single thing at a time, and the
resulting command can grow long quite quickly. Because of this, PFERD can also
be used with a config file.To get started, just take a command you've been using and add--dump-configdirectly afterpferd, like this:$ pferd --dump-config kit-ilias-web <url> <output_directory>This will make PFERD write its current configuration to its default config file
path. You can then runpferdwithout a command and it will execute the config
file. Alternatively, you can use--dump-config-toand specify a path yourself.
Using--dump-config-to -will print the configuration to stdout instead of a
file, which is a good way to see what is actually going on when using a CLI
command.Another good way to see what PFERD is doing is the--explainoption. When
enabled, PFERD explains in detail what it is doing and why. This can help with
debugging your own config.If you don't want to run all crawlers from your config file, you can specify the
crawlers you want to run with--crawleror-C, like this:$ pferd -C crawler1 -C crawler2Advanced usagePFERD supports lots of different options. For example, you can configure PFERD
touse your system's keyringinstead of
prompting you for your username and password. PFERD also supportstransformation rulesthat let you rename or
exclude certain files.For more details, see the comprehensiveconfig format documentation.ExampleThis example downloads a few courses from the KIT ILIAS with a common keyring
authenticator. It reorganizes and ignores some files.[DEFAULT]# All paths will be relative to this.# The crawler output directories will be <working_dir>/Foo and <working_dir>/Bar.working_dir=~/stud# If files vanish from ILIAS the local files are not deleted, allowing us to# take a look at them before deleting them ourselves.on_conflict=no-delete[auth:ilias]type=keyringusername=foo[crawl:Foo]type=kit-ilias-webauth=auth:ilias# Crawl a course by its ID (found as `ref_id=ID` in the URL)target=1234567# Plaintext files are easier to read by other toolslinks=plaintexttransform=# Ignore unneeded foldersOnline-Tests --> !Vorlesungswerbung --> !# Rename foldersLehrbücher --> Vorlesung# Note the ">>" arrow head which lets us apply further rules to files moved to "Übung"Übungsunterlagen -->> Übung# Move exercises to own folder. Rename them to "Blatt-XX.pdf" to make them sort properly"Übung/(\d+). Übungsblatt.pdf" -re-> Blätter/Blatt-{i1:02}.pdf# Move solutions to own folder. Rename them to "Blatt-XX-Lösung.pdf" to make them sort properly"Übung/(\d+). Übungsblatt.*Musterlösung.pdf" -re-> Blätter/Blatt-{i1:02}-Lösung.pdf# The course has nested folders with the same name - flatten them"Übung/(.+?)/\\1" -re-> Übung/{g1}[crawl:Bar]type=kit-ilias-webauth=auth:iliastarget=1337420