nora 0.7 → 0.8
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/nora/core.rb +10 -3
- data/lib/nora/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f489b522ee593bfba2e454facb6ee96cca9a6c59
|
4
|
+
data.tar.gz: e69fdfdd63b93b7f46bfd6ce537f8443fc5a3dc9
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 627975b00784b00875e88b31508d6ccac83bd070b6ec4771cb0d7c69e5c1dcd174d7a1f0096fcc07a1a2c4c09d3387689ccb1613bc3eae6ce25b05bdbdf0e4c1
|
7
|
+
data.tar.gz: 0a0d5cfe13c64e7eaf61a68bde5f1e3aacf556f93f8ecdcd063f88017e0e885a65ace03271cd0ea4cf1b8e64d4004bcf1ced00166a85698249f9642b203e2b1e
|
data/lib/nora/core.rb
CHANGED
@@ -46,8 +46,6 @@ module Nora
|
|
46
46
|
}
|
47
47
|
|
48
48
|
def initialize(weeks_ahead:, test:)
|
49
|
-
puts
|
50
|
-
|
51
49
|
@weeks_ahead = weeks_ahead
|
52
50
|
@test = test
|
53
51
|
|
@@ -93,7 +91,16 @@ module Nora
|
|
93
91
|
def load_calendars!
|
94
92
|
puts "Loading calendars..."
|
95
93
|
@emails = CONFIGURATION["people"].map { |p| p["email"] }
|
96
|
-
|
94
|
+
|
95
|
+
emails_in_history = []
|
96
|
+
File.open(PAIRINGS_FILE).each do |line|
|
97
|
+
line.split(PAIRINGS_FILE_SEPARATOR).each do |email|
|
98
|
+
emails_in_history << email
|
99
|
+
end
|
100
|
+
end
|
101
|
+
|
102
|
+
# Load all calendars that aren't in our history.
|
103
|
+
(@emails - emails_in_history).each do |email|
|
97
104
|
puts "Loading calendar: #{email}"
|
98
105
|
@service.insert_calendar_list(
|
99
106
|
Google::Apis::CalendarV3::CalendarListEntry.new(id: email)
|
data/lib/nora/version.rb
CHANGED