Skip to content

Commit

Permalink
Add files via upload
Browse files Browse the repository at this point in the history
  • Loading branch information
tuffstuff9 authored Aug 13, 2022
0 parents commit 97fb95e
Show file tree
Hide file tree
Showing 6 changed files with 4,074 additions and 0 deletions.
21 changes: 21 additions & 0 deletions LICENSE.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) [year] [fullname]

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
Empty file added README.md
Empty file.
24 changes: 24 additions & 0 deletions index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
const { scrapeCourses } = require('./scraper');

// EDIT THESE ----------------------------------------------------------------

// The course category and course number you want to track. Example below
const COURSE_CATEGORY = 'Computer Science (CSCI-UA)';
const COURSE_NUMBER = '7441';

// Telegram info for alerts
// Watch a youtube video on 'telegram bot' to learn how to obtain these
const TOKEN = 'ENTER YOUR TOKEN HERE';
const CHAT_ID = 'ENTER YOUR CHAT ID HERE';

// Will run randomly somewhere between every 3-6 seconds.
// Adjust as you wish
var INTERVAL_MIN = 3000;
var INTERVAL_MAX = 6000;
// ---------------------------------------------------------------------------

var interval = parseInt(
Math.random() * (INTERVAL_MAX - INTERVAL_MIN) + INTERVAL_MIN
);

scrapeCourses(COURSE_CATEGORY, COURSE_NUMBER, TOKEN, CHAT_ID, interval);
Loading

0 comments on commit 97fb95e

Please sign in to comment.