An open API service indexing awesome lists of open source software.

https://github.com/malb/moodle-cli

Basic command line interface for Moodle using Selenium (!) because we can't have nice things
https://github.com/malb/moodle-cli

Last synced: about 1 year ago
JSON representation

Basic command line interface for Moodle using Selenium (!) because we can't have nice things

Awesome Lists containing this project

README

          

#+TITLE: Basic Selenium-based Moodle CLI

* Why?

My university doesn’t enable the Moodle API but Moodle’s web interface is horrible and clunky.

* What can it do?

Not much!

#+BEGIN_SRC sh :results verbatim :exports results
./cli.py
#+END_SRC

#+RESULTS:
: Usage: cli.py [OPTIONS] COMMAND [ARGS]...
:
: Options:
: --help Show this message and exit.
:
: Commands:
: list-files List files of a course.
: set-text Set the summary text of a section from a...
: upload-file Upload a file.

* It doesn’t work!

The whole thing is rather fragile as it depends on Moodle’s internal HTML representation which changes from version to version. I’m testing/using it on the Moodle install of my university. I’m happy to use as generic XPATH as possible to support more Moodle versions, but I have no intention of promising any support for anything other than whatever my university is running at the moment.