regis-lector 0.9.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: cb2b34ab71515a7a6979b311e53851eb74227c83
4
+ data.tar.gz: e4b97553964c95e606698388ad0d5b61b48ad60b
5
+ SHA512:
6
+ metadata.gz: 97569f6da326d5c86540cd2874eaf307a48c56a91c009da083b15dedd19f0731455c939f462ddee59f1da9c763fe910bd3ac4b464ab2d3041850160fc639c4a4
7
+ data.tar.gz: c6f69190688f7c02fdf5f055f181f57f5f713e5b52515e1fdb48ed326b23177689f493b69bf82655706ea7a6e71207c5544da6343dd02a518c9c14a1ca9566d5
@@ -0,0 +1,12 @@
1
+ /.bundle/
2
+ /.yardoc
3
+ /Gemfile.lock
4
+ /_yardoc/
5
+ /coverage/
6
+ /doc/
7
+ /pkg/
8
+ /spec/reports/
9
+ /tmp/
10
+
11
+ /data/config.yaml
12
+ /data/veracross.json
@@ -0,0 +1,5 @@
1
+ sudo: false
2
+ language: ruby
3
+ rvm:
4
+ - 2.3.0
5
+ before_install: gem install bundler -v 1.13.1
@@ -0,0 +1,74 @@
1
+ # Contributor Covenant Code of Conduct
2
+
3
+ ## Our Pledge
4
+
5
+ In the interest of fostering an open and welcoming environment, we as
6
+ contributors and maintainers pledge to making participation in our project and
7
+ our community a harassment-free experience for everyone, regardless of age, body
8
+ size, disability, ethnicity, gender identity and expression, level of experience,
9
+ nationality, personal appearance, race, religion, or sexual identity and
10
+ orientation.
11
+
12
+ ## Our Standards
13
+
14
+ Examples of behavior that contributes to creating a positive environment
15
+ include:
16
+
17
+ * Using welcoming and inclusive language
18
+ * Being respectful of differing viewpoints and experiences
19
+ * Gracefully accepting constructive criticism
20
+ * Focusing on what is best for the community
21
+ * Showing empathy towards other community members
22
+
23
+ Examples of unacceptable behavior by participants include:
24
+
25
+ * The use of sexualized language or imagery and unwelcome sexual attention or
26
+ advances
27
+ * Trolling, insulting/derogatory comments, and personal or political attacks
28
+ * Public or private harassment
29
+ * Publishing others' private information, such as a physical or electronic
30
+ address, without explicit permission
31
+ * Other conduct which could reasonably be considered inappropriate in a
32
+ professional setting
33
+
34
+ ## Our Responsibilities
35
+
36
+ Project maintainers are responsible for clarifying the standards of acceptable
37
+ behavior and are expected to take appropriate and fair corrective action in
38
+ response to any instances of unacceptable behavior.
39
+
40
+ Project maintainers have the right and responsibility to remove, edit, or
41
+ reject comments, commits, code, wiki edits, issues, and other contributions
42
+ that are not aligned to this Code of Conduct, or to ban temporarily or
43
+ permanently any contributor for other behaviors that they deem inappropriate,
44
+ threatening, offensive, or harmful.
45
+
46
+ ## Scope
47
+
48
+ This Code of Conduct applies both within project spaces and in public spaces
49
+ when an individual is representing the project or its community. Examples of
50
+ representing a project or community include using an official project e-mail
51
+ address, posting via an official social media account, or acting as an appointed
52
+ representative at an online or offline event. Representation of a project may be
53
+ further defined and clarified by project maintainers.
54
+
55
+ ## Enforcement
56
+
57
+ Instances of abusive, harassing, or otherwise unacceptable behavior may be
58
+ reported by contacting the project team at thefrankmatranga@gmail.com. All
59
+ complaints will be reviewed and investigated and will result in a response that
60
+ is deemed necessary and appropriate to the circumstances. The project team is
61
+ obligated to maintain confidentiality with regard to the reporter of an incident.
62
+ Further details of specific enforcement policies may be posted separately.
63
+
64
+ Project maintainers who do not follow or enforce the Code of Conduct in good
65
+ faith may face temporary or permanent repercussions as determined by other
66
+ members of the project's leadership.
67
+
68
+ ## Attribution
69
+
70
+ This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
71
+ available at [http://contributor-covenant.org/version/1/4][version]
72
+
73
+ [homepage]: http://contributor-covenant.org
74
+ [version]: http://contributor-covenant.org/version/1/4/
data/Gemfile ADDED
@@ -0,0 +1,8 @@
1
+ source 'https://rubygems.org'
2
+
3
+ # Specify your gem's dependencies in lector.gemspec
4
+ gemspec
5
+
6
+ gem 'mysql2'
7
+ gem 'activerecord'
8
+ gem 'mechanize'
data/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2017 Frank Matranga
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2017 Frank Matranga
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in
13
+ all copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
+ THE SOFTWARE.
@@ -0,0 +1,37 @@
1
+ # Lector
2
+
3
+ **Lector** is a Ruby gem written specifically for my high school's Moodle site. It can login as a student and then web scrape info on staff, teachers, students, and courses.
4
+
5
+ ## Installation
6
+
7
+ Add this line to your application's Gemfile:
8
+
9
+ ```ruby
10
+ gem 'lector'
11
+ ```
12
+
13
+ And then execute:
14
+
15
+ $ bundle
16
+
17
+ Or install it yourself as:
18
+
19
+ $ gem install lector
20
+
21
+ ## Usage
22
+
23
+ Documentation can be found at TODO: LINK
24
+
25
+ ## Development
26
+
27
+ I still don't know much about real development of Ruby gems so if you want to contribute just clone, edit, and submit a pull request.
28
+
29
+ ## Contributing
30
+
31
+ Bug reports and pull requests are welcome on GitHub at https://github.com/[USERNAME]/lector. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [Contributor Covenant](http://contributor-covenant.org) code of conduct.
32
+
33
+
34
+ ## License
35
+
36
+ The gem is available as open source under the terms of the [MIT License](http://opensource.org/licenses/MIT).
37
+
@@ -0,0 +1,10 @@
1
+ require "bundler/gem_tasks"
2
+ require "rake/testtask"
3
+
4
+ Rake::TestTask.new(:test) do |t|
5
+ t.libs << "test"
6
+ t.libs << "lib"
7
+ t.test_files = FileList['test/**/*_test.rb']
8
+ end
9
+
10
+ task :default => :test
@@ -0,0 +1,19 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ require "bundler/setup"
4
+ require "lector"
5
+ require "yaml"
6
+ require "pp"
7
+
8
+ PATH = "/home/frank/Projects/lector/data/config.yaml"
9
+ CONFIG = YAML.load_file(PATH)
10
+
11
+ # You can add fixtures and/or initialization code here to make experimenting
12
+ # with your gem easier. You can also use a different console, if you like.
13
+
14
+ # (If you use this, don't forget to add pry to your Gemfile!)
15
+ # require "pry"
16
+ # Pry.start
17
+
18
+ require "irb"
19
+ IRB.start
@@ -0,0 +1,23 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ require "bundler/setup"
4
+ require "lector"
5
+ require "yaml"
6
+ require "pp"
7
+
8
+ PATH = "/home/frank/Projects/lector/data/config.yaml"
9
+ CONFIG = YAML.load_file(PATH)
10
+
11
+ LECTOR = Lector.new(CONFIG)
12
+
13
+ # LOOP THROUGH COURSES
14
+ puts "LOOPING THROUGH COURSES"
15
+ 800.times do |id|
16
+ LECTOR.scrape_and_save(id + 1, :course)
17
+ end
18
+
19
+ # LOOP THROUGH PEOPLE
20
+ puts "LOOPING THROUGH PEOPLE"
21
+ 3000.times do |id|
22
+ LECTOR.scrape_and_save(id + 1, :person)
23
+ end
@@ -0,0 +1,8 @@
1
+ #!/usr/bin/env bash
2
+ set -euo pipefail
3
+ IFS=$'\n\t'
4
+ set -vx
5
+
6
+ bundle install
7
+
8
+ # Do any other automated setup that you need to do here
@@ -0,0 +1,26 @@
1
+ # coding: utf-8
2
+ lib = File.expand_path('../lib', __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+
5
+ Gem::Specification.new do |spec|
6
+ spec.name = "regis-lector"
7
+ spec.version = "0.9.0"
8
+ spec.authors = ["Frank Matranga"]
9
+ spec.email = ["thefrankmatranga@gmail.com"]
10
+
11
+ spec.summary = %q{Simple Moodle Scraper}
12
+ spec.description = %q{Super simple Moodle site scraper for Frank Matranga's high school}
13
+ spec.homepage = "https://github.com/Apexal/lector"
14
+ spec.license = "MIT"
15
+
16
+ spec.files = `git ls-files -z`.split("\x0").reject do |f|
17
+ f.match(%r{^(test|spec|features)/})
18
+ end
19
+ spec.bindir = "exe"
20
+ spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
21
+ spec.require_paths = ["lib"]
22
+
23
+ spec.add_development_dependency "bundler", "~> 1.13"
24
+ spec.add_development_dependency "rake", "~> 10.0"
25
+ spec.add_development_dependency "minitest", "~> 5.0"
26
+ end
@@ -0,0 +1,63 @@
1
+ require 'rubygems'
2
+
3
+ require 'date'
4
+ require 'yaml'
5
+ require 'mysql2'
6
+ require 'active_record'
7
+ require 'mechanize'
8
+
9
+ require 'bundler/setup'
10
+ Bundler.setup(:default)
11
+
12
+ # Require all modules
13
+ Dir["#{File.dirname(__FILE__)}/lector/*.rb"].each { |file| require file }
14
+
15
+ class Lector
16
+ @@defaults = {
17
+ db_host: 'localhost',
18
+ db_database: 'lector',
19
+ db_username: 'root',
20
+ db_password: '',
21
+ regis_username: '',
22
+ regis_password: '',
23
+ veracross_path: "#{Dir.pwd}/data/veracross.json"
24
+ }
25
+
26
+ VERSION = "0.9.0"
27
+
28
+ include Database
29
+ include Veracross
30
+ include Scraper
31
+
32
+ attr_reader :logged_in
33
+
34
+ def initialize(config)
35
+ puts "Lector v#{VERSION}"
36
+
37
+ # Fill in any blanks
38
+ @config = @@defaults.merge(config)
39
+ load_veracross
40
+
41
+ # First try to login to Moodle
42
+ login_to_moodle
43
+
44
+ # Connect to DB
45
+ connect_db
46
+
47
+ nil
48
+ end
49
+
50
+ def scrape_and_save(id, type)
51
+ puts "Scraping and saving #{type.to_s} with Moodle ID #{id}"
52
+ begin
53
+ return case type
54
+ when :person
55
+ save_person(extract_person(id))
56
+ when :course
57
+ save_course(extract_course(id))
58
+ end
59
+ rescue => e
60
+ puts "Failed to scrape and save #{type.to_s} with ID: #{id}\n#{e}"
61
+ end
62
+ end
63
+ end
@@ -0,0 +1,91 @@
1
+ module Database
2
+ def connect_db
3
+ puts "Connecting to MySQL DB at #{@config[:db_host]}"
4
+ ActiveRecord::Base.establish_connection(
5
+ adapter: 'mysql2',
6
+ host: @config[:db_host],
7
+ database: @config[:db_database],
8
+ username: @config[:db_username],
9
+ password: @config[:db_password]
10
+ )
11
+ end
12
+
13
+ class Student < ActiveRecord::Base
14
+ has_and_belongs_to_many :courses
15
+ end
16
+
17
+ class Course < ActiveRecord::Base
18
+ belongs_to :staff, inverse_of: :courses, foreign_key: 'teacher_id'
19
+ has_and_belongs_to_many :students
20
+ end
21
+
22
+ class Staff < ActiveRecord::Base
23
+ has_and_belongs_to_many :courses
24
+ end
25
+
26
+ # Determine staff or student
27
+ def save_person(info)
28
+ return case info[:type]
29
+ when :student
30
+ save_student(info)
31
+ else
32
+ save_staff(info)
33
+ end
34
+ end
35
+
36
+ def save_course(info)
37
+ info.delete(:type)
38
+
39
+ # DB throws error if doesn't exist so resort to nil if throws
40
+ course = Course.find(info[:id]) rescue nil
41
+
42
+ if course.nil?
43
+ course = Course.create(info)
44
+ else
45
+ course.update(info)
46
+ end
47
+
48
+ course.save!
49
+ course
50
+ end
51
+
52
+ def save_staff(info)
53
+ info.delete(:type)
54
+
55
+ # DB throws error if doesn't exist so resort to nil if throws
56
+ staff = Staff.find(info[:id]) rescue nil
57
+
58
+ course_ids = info.delete(:course_ids)
59
+
60
+ if staff.nil?
61
+ staff = Staff.create(info)
62
+ else
63
+ staff.update(info)
64
+ end
65
+
66
+ staff.courses = Course.where(id: course_ids) # Throws error if courses don't exist
67
+
68
+ staff.save!
69
+ staff
70
+ end
71
+
72
+ def save_student(info)
73
+ info.delete(:type)
74
+
75
+ # DB throws error if doesn't exist so resort to nil if throws
76
+ student = Student.find(info[:id]) rescue nil
77
+
78
+ course_ids = info.delete(:course_ids)
79
+
80
+ if student.nil?
81
+ student = Student.create(info)
82
+ else
83
+ student.update(info)
84
+ end
85
+
86
+ student.courses = Course.where(id: course_ids) # Throws error if courses don't exist
87
+
88
+ student.save!
89
+ student
90
+ end
91
+ end
@@ -0,0 +1,7 @@
1
+ module Exceptions
2
+ class InvalidCredentialsError < StandardError
3
+ end
4
+
5
+ class InvalidPageError < StandardError
6
+ end
7
+ end
@@ -0,0 +1,14 @@
1
+ module StoreData
2
+ # Serializes an object and saves it to file.
3
+ def save_to_file(file, object)
4
+ File.open(file, 'w') do |f|
5
+ f.write YAML.dump(object)
6
+ end
7
+ end
8
+
9
+ # Loads yaml from file or returns an empty hash if file doesn't exist.
10
+ def load_file(file)
11
+ return YAML.load_file(file) if File.exist?(file)
12
+ {}
13
+ end
14
+ end
@@ -0,0 +1,125 @@
1
+ module Scraper
2
+ include Exceptions
3
+ include Veracross
4
+
5
+ # Constants
6
+ AGENT = Mechanize.new
7
+ AGENT.user_agent_alias = 'Linux Firefox'
8
+
9
+ GRADES = %w(Freshmen Sophomores Juniors Seniors).freeze
10
+ SINGULAR_GRADES = %w(Freshman Sophomore Junior Senior).freeze
11
+ ADVISEMENT_TO_GRAD_YEAR = {'1' => 20, '2' => 19, '3' => 18, '4' => 17}
12
+ COURSE_TITLE_IGNORES = %w(Department REACH Advisement Office NYSAIS)
13
+ SUCCESSFUL_LOGIN_PAGE_TITLE = 'Dashboard'
14
+ IGNORE_TITLES = %w(Notice Error Test Parent Nurse Student)
15
+
16
+ def login_to_moodle
17
+ puts "Attempting to login to Moodle as #{@config[:regis_username]}..."
18
+ puts AGENT
19
+ page = AGENT.post('https://moodle.regis.org/login/index.php', {
20
+ username: @config[:regis_username],
21
+ password: @config[:regis_password],
22
+ })
23
+
24
+ raise InvalidCredentialsError, 'Invalid Regis credentials! Couldn\'t log into Moodle.' unless page.title == SUCCESSFUL_LOGIN_PAGE_TITLE
25
+
26
+ true
27
+ end
28
+
29
+ def get_profile(id, type)
30
+ base_url = (type == :person ? 'http://moodle.regis.org/user/profile.php?id=' : 'http://moodle.regis.org/course/view.php?id=')
31
+
32
+ # Request page
33
+ page = AGENT.get(base_url + id.to_s)
34
+
35
+ # Discard unneccessary pages
36
+ raise InvalidPageError, "Invalid page: '#{page.title}'" if page.title.nil? || IGNORE_TITLES.any? { |w| page.title.downcase.include?(w.downcase) }
37
+ raise InvalidPageError, "Name is too short: '#{page.title}'" if page.title.split(':').length < 2
38
+
39
+ page
40
+ end
41
+
42
+ def extract_person(id)
43
+ page = get_profile(id, :person)
44
+
45
+ title = page.title
46
+
47
+ name = title.split(':')[0].split(' ')
48
+ first_name = name[0]
49
+ last_name = name[1..-1].join(' ')
50
+
51
+ picture_url = nil
52
+ begin
53
+ picture_url = page.search("a/img[@alt=\"Picture of #{first_name} #{last_name}\"]")[0]['src']
54
+ rescue => e
55
+ puts e
56
+ raise InvalidPageError, 'Page doesn\'t have picture.'
57
+ end
58
+
59
+ # DEPARTMENT (advisement for students, subject for staff)
60
+ department = page.search("//dd[../dt = 'Department']/text()").to_s
61
+
62
+ type = (/\A\d+\z/.match(department[0]) || department.empty? ? :student : :staff)
63
+
64
+ username_guess = (type == :staff ? "#{first_name[0]}#{last_name}" : "#{first_name[0]}#{last_name}#{Lector::ADVISEMENT_TO_GRAD_YEAR[department[0]]}").downcase.gsub("'", '').gsub('-', '').gsub(' ', '')
65
+
66
+ returning = {
67
+ id: id,
68
+ type: type,
69
+ first_name: first_name,
70
+ last_name: last_name,
71
+ email: username_guess + '@regis.org',
72
+ department: department,
73
+ pictureurl: picture_url,
74
+ username: username_guess,
75
+ course_ids: page.search("//dd/ul/li/a[contains(@href, 'http://moodle.regis.org/course/view.php?id=')]").map { |link| link["href"].split("id=")[1].split("&")[0] }
76
+ }
77
+
78
+ if type == :student
79
+ # FIND INFO FROM VERACROSS
80
+ info = find_by_username_or_email(username_guess)
81
+ raise InvalidPageError, 'Student doesn\'t exist. Failed to link to Veracross data.' if info.nil?
82
+
83
+ returning[:advisement] = returning.delete(:department)
84
+ returning[:veracross_id] = info['person_pk']
85
+ returning[:pictureurl] = info['photo_url']
86
+ returning[:graduation_year] = info['graduation_year']
87
+ returning[:address] = info['resident_address'].sub('<br />', ' ')
88
+ returning[:birthday] = Date.parse(info['birthday'])
89
+ end
90
+
91
+ puts "#{id}: #{type.capitalize} #{last_name}, #{first_name} of #{department} (#{username_guess})"
92
+
93
+ returning
94
+ end
95
+
96
+ def extract_course(id)
97
+ page = get_profile(id, :course)
98
+
99
+ parts = page.title.split(':')
100
+ is_class = parts.length > 2 # Classes have a teacher, title would have ': Teacher Name'
101
+
102
+ # Course: Theater Production: Grunner
103
+ title = (parts.length == 1 ? parts[0] : parts[1]).strip
104
+
105
+ raise "#{id}: Ignoring 'course' #{title}" if COURSE_TITLE_IGNORES.any? { |ignore| title.end_with?(ignore) || title.start_with?(ignore) }
106
+
107
+ returning = {
108
+ type: :course,
109
+ id: id,
110
+ title: title,
111
+ is_class: is_class
112
+ }
113
+
114
+ if is_class
115
+ # Find teacher
116
+ teacher_page = AGENT.get("http://moodle.regis.org/user/index.php?roleid=3&sifirst=&silast=&id=#{id.to_s}")
117
+ returning[:teacher_id] = teacher_page.search("//strong/a[contains(@href, 'moodle.regis.org')]")[0]['href'].split("?id=")[1].split("&course=")[0].to_i
118
+ end
119
+
120
+ puts "#{id}: Course #{parts[1..-1].join}#{" (class)" if is_class}"
121
+
122
+ returning
123
+ end
124
+
125
+ end
@@ -0,0 +1,25 @@
1
+ module Veracross
2
+ # USEFUL PROPERTIES
3
+ # first_name
4
+ # last_name
5
+ # birthday
6
+ # grade_level
7
+ # graduation_year
8
+ # advisor
9
+ # address
10
+ # email
11
+
12
+ def load_veracross
13
+ puts "Loading Veracross data from #{@config[:veracross_path]}"
14
+ path = @config[:veracross_path]
15
+ @data = JSON.load(File.read(path))
16
+
17
+ puts "Loaded #{@data.length} students"
18
+ end
19
+
20
+ def find_by_username_or_email(u_or_e)
21
+ load if @data.nil?
22
+ email = (u_or_e.end_with?('@regis.org') ? u_or_e : u_or_e + '@regis.org')
23
+ @data.find { |entry| entry['email'] == email }
24
+ end
25
+ end
data/run.rb ADDED
@@ -0,0 +1 @@
1
+ require_relative 'lib/lector.rb'
metadata ADDED
@@ -0,0 +1,105 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: regis-lector
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.9.0
5
+ platform: ruby
6
+ authors:
7
+ - Frank Matranga
8
+ autorequire:
9
+ bindir: exe
10
+ cert_chain: []
11
+ date: 2017-06-08 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: bundler
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: '1.13'
20
+ type: :development
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: '1.13'
27
+ - !ruby/object:Gem::Dependency
28
+ name: rake
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: '10.0'
34
+ type: :development
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: '10.0'
41
+ - !ruby/object:Gem::Dependency
42
+ name: minitest
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - "~>"
46
+ - !ruby/object:Gem::Version
47
+ version: '5.0'
48
+ type: :development
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - "~>"
53
+ - !ruby/object:Gem::Version
54
+ version: '5.0'
55
+ description: Super simple Moodle site scraper for Frank Matranga's high school
56
+ email:
57
+ - thefrankmatranga@gmail.com
58
+ executables: []
59
+ extensions: []
60
+ extra_rdoc_files: []
61
+ files:
62
+ - ".gitignore"
63
+ - ".travis.yml"
64
+ - CODE_OF_CONDUCT.md
65
+ - Gemfile
66
+ - LICENSE
67
+ - LICENSE.txt
68
+ - README.md
69
+ - Rakefile
70
+ - bin/console
71
+ - bin/loop
72
+ - bin/setup
73
+ - lector.gemspec
74
+ - lib/lector.rb
75
+ - lib/lector/database.rb
76
+ - lib/lector/exceptions.rb
77
+ - lib/lector/other/storedata.rb
78
+ - lib/lector/scraper.rb
79
+ - lib/lector/veracross.rb
80
+ - run.rb
81
+ homepage: https://github.com/Apexal/lector
82
+ licenses:
83
+ - MIT
84
+ metadata: {}
85
+ post_install_message:
86
+ rdoc_options: []
87
+ require_paths:
88
+ - lib
89
+ required_ruby_version: !ruby/object:Gem::Requirement
90
+ requirements:
91
+ - - ">="
92
+ - !ruby/object:Gem::Version
93
+ version: '0'
94
+ required_rubygems_version: !ruby/object:Gem::Requirement
95
+ requirements:
96
+ - - ">="
97
+ - !ruby/object:Gem::Version
98
+ version: '0'
99
+ requirements: []
100
+ rubyforge_project:
101
+ rubygems_version: 2.6.12
102
+ signing_key:
103
+ specification_version: 4
104
+ summary: Simple Moodle Scraper
105
+ test_files: []