You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It would be neat to allow end-users to use some form of templating language to provide messages to students. Just as a rough example, consider the update command that updates student repositories, and opens an issue if it fails. It would be nice if the issue could be personalized to the student. For example, the issue body could look like this:
Hello {{ student_name }},
Your repository requires a patch that we could not apply automatically. Please apply this patch:
{{ patch }}
Here, {{ student_name }} would then be replaced with the student's (or students') name(s), and {{ patch }} would be replaced with the patch in question (which RepoBee should be able to figure out automatically by just finding a merge base between the student's branch and the branch that we tried to push).
From the developer's point of view, it should be possible to just invoke a function (e.g. process_template) and provide it with the legal variables for the template. Here, for example, processing this template could look like:
Another example is if you were to run repos setup, and at the end you want to post a message to some LMS platform (through a plugin). Then, hypothetically, a call to setup could look like this:
So, here, each student would get a comment on the LMS platform, on the given assignment, that their repository is now available, and it would read something like Repository available: https://some.gitlab.instance/some-course/bob/bob-task-1
We could probably use jinja2 to implement this smoothly, but depending on the limitations we want to put on the templating we may want to do something custom instead.
Suggestions on this functionality are welcome!
The text was updated successfully, but these errors were encountered:
It would be neat to allow end-users to use some form of templating language to provide messages to students. Just as a rough example, consider the update command that updates student repositories, and opens an issue if it fails. It would be nice if the issue could be personalized to the student. For example, the issue body could look like this:
Here,
{{ student_name }}
would then be replaced with the student's (or students') name(s), and{{ patch }}
would be replaced with the patch in question (which RepoBee should be able to figure out automatically by just finding a merge base between the student's branch and the branch that we tried to push).From the developer's point of view, it should be possible to just invoke a function (e.g.
process_template
) and provide it with the legal variables for the template. Here, for example, processing this template could look like:Another example is if you were to run
repos setup
, and at the end you want to post a message to some LMS platform (through a plugin). Then, hypothetically, a call tosetup
could look like this:So, here, each student would get a comment on the LMS platform, on the given assignment, that their repository is now available, and it would read something like
Repository available: https://some.gitlab.instance/some-course/bob/bob-task-1
We could probably use jinja2 to implement this smoothly, but depending on the limitations we want to put on the templating we may want to do something custom instead.
Suggestions on this functionality are welcome!
The text was updated successfully, but these errors were encountered: