Coder Social home page Coder Social logo

zearibrahim / brutime Goto Github PK

View Code? Open in Web Editor NEW

This project forked from bencevans/brutime

0.0 0.0 0.0 187 KB

๐Ÿ—“๏ธ Scrape timetabling info for Brunel Uni students.

Home Page: https://www.npmjs.com/package/brutime

JavaScript 100.00%

brutime's Introduction

brutime

Node.js module for scraping data from Brunel University's timetabling portal.

โš ๏ธ This README is out of date and shall be updated soon once the puppeteer rewrites are complete.

Install

$ npm install --save brutime

Usage

Instantiate client

const BruTime = require("brutime");

// Create an instance of BruTime with your login/password.
var timetable = new BruTime({
  login: "1156145",
  password: "my password",
});

.listMyModules() - List your enrolled modules

// List Enrolled Modules
timetable.listMyModules(function (err, myModules) {
  if (err) {
    throw err;
  }
  // myModules === ['CS2001', 'CS2002', 'CS2003']
  console.log("My Modules: " + myModules.join(", "));
  // Prints: CS2001, CS2002, CS2003
});

.getMyModulesTimetable() - List contact hours for your enrolled modules

timetable.getMyModulesTimetable(
  {
    period: "1-12",
    days: "1-7",
  },
  function (err, timetable) {
    if (err) {
      return console.error(err);
    }
    console.log(timetable);
  }
);

Testing

$  export LOGIN=YOUR_STUDENT_ID
$  export PASSWORD=YOUR_STUDENT_PASSWORD
$ npm test

Related

  • bencevans/brugrade - Brunel's undergraduate marking/grade bounds dataset and byMark(grade) search.

Licence

MIT ยฉ Ben Evans

brutime's People

Contributors

bencevans avatar greenkeeperio-bot avatar bhammonds avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.