Skip to content
Snippets Groups Projects
Select Git revision
  • master default protected
1 result

scripts

  • Clone with SSH
  • Clone with HTTPS
  • Scripts for automating CSCE 361 tasks

    These scripts are designed to automate the creation, population, and staffing of repositories for student assignments.

    Requires

    Files

    • config.py

      • provides URLs and API keys
      • ignored (not present in remote repository)
    • config-example.py

      • sample config.py file, without API keys
      • do not commit API keys to repository
        • you will need to copy to config.py and replace None with your API keys (as strings)
    • course.py

      • provides namespace and group ID
        • will need to update each semester
    • prep_assignment.py

      • An early iteration of automated student pairing, canvas student group creation, and gitlab repo creation. It lacks robustness to odd number of students; it has a quick'n'dirty loop termination that does not guarantee graylist compliance, and project naming is hard-coded. Also does not tolerate non-existent usernames.
    • api/

      • canvas_classes.py
        • Classes to encapsulate concepts from Canvas CMS
      • gitlab_classes.py
        • Classes to encapsulate concepts from Gitlab VMS
      • composite_user.py
        • Wrapper class that pairs a user from Canvas with the corresponding user from Gitlab
    • local/

      • ignored directory (not present in remote repository) for local copies of files
        • you might keep a config.py with read/write api keys and another with read-only api keys here, to place in top-level directory as you see fit
        • you might keep copies of the course csv file(s) here, but bear in mind that they won't be backed up

    Older Files

    These are vestigial files that should not be needed further, but we are retaining until we are certain.

    • old-automation/
      • Directory containing early fall 2019 scripts to clone, create, process, etc., student repositories. The contents of this directory are not needed.
      • 1195/
        • Directory containing scripts from summer 2019 pilot of new course structure. Should be obsolete (and removed) by end of fall 2019. The contents of this directory are not needed.
    • experimentation/
      • gitlab_functions.py - provides functions to query & update projects (including its members and issues) - These functions are those we believe are useful for automating pair & team projects for CSCE 361 - These generally are wrappers for calls you could make directly from what python-gitlab provides, but these functions don't require you to memorize the api - includes an enumeration of the fields for User, Project, and Issue - includes side-effect-free example function calls
      • gitlab_demo.py
        • includes commented-out functions demonstrating the creation of projects, adding users to projects, and creating/updating the projects' issues
      • canvas_experiments.py
        • includes experimental use of the Canvas API, culminating in creating a group set (group_category), adding groups to it, and adding students to a group