et-orbi 1.2.7 → 1.2.8
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.
- checksums.yaml +4 -4
- data/CHANGELOG.md +5 -0
- data/CREDITS.md +1 -0
- data/LICENSE.txt +1 -1
- data/Makefile +4 -4
- data/README.md +0 -1
- data/lib/et-orbi/time.rb +12 -4
- data/lib/et-orbi.rb +1 -1
- metadata +6 -6
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 149c5b95f1f67702640cb1b202d768bec7e215bb6335f9ec73f247d65edb6298
|
|
4
|
+
data.tar.gz: 6e559b757f53c60daef8be08c9c9af0d48378e203cc3d7cbb5582b4bb758b051
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 58d548986bc13f557c88cb862f52c10faa9211489a0daa0de7691eea5473905554a3257166d689c128d1a14d97c000713de17ee5064c557eaf601f718ee26b2b
|
|
7
|
+
data.tar.gz: 4919107bc2091bb8be87af751e86f75bf99f5f29fae457f12321b85bfc38ec38ad47a533e4a706f27bbd409b0bd92e479c9f44b9b01f5dc2adc18a839b2232cc
|
data/CHANGELOG.md
CHANGED
data/CREDITS.md
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
|
|
2
2
|
# et-orbi credits
|
|
3
3
|
|
|
4
|
+
* Igor Viktor https://github.com/gogainda gh-34
|
|
4
5
|
* phibid, for https://github.com/floraison/fugit/issues/67
|
|
5
6
|
* Peter Goldstein, https://github.com/petergoldstein GHA 3.3 j9.3, gh-32
|
|
6
7
|
* harsha-flipp (https://github.com/harsha-flipp) https://github.com/floraison/fugit/issues/63
|
data/LICENSE.txt
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
|
|
2
|
-
Copyright (c) 2017-
|
|
2
|
+
Copyright (c) 2017-2024, John Mettraux, jmettraux+flor@gmail.com
|
|
3
3
|
|
|
4
4
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
5
5
|
of this software and associated documentation files (the "Software"), to deal
|
data/Makefile
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
|
|
2
2
|
## gem tasks ##
|
|
3
3
|
|
|
4
|
-
NAME
|
|
5
|
-
|
|
6
|
-
VERSION
|
|
7
|
-
|
|
4
|
+
NAME != \
|
|
5
|
+
ruby -e "s = eval(File.read(Dir['*.gemspec'][0])); puts s.name"
|
|
6
|
+
VERSION != \
|
|
7
|
+
ruby -e "s = eval(File.read(Dir['*.gemspec'][0])); puts s.version"
|
|
8
8
|
|
|
9
9
|
count_lines:
|
|
10
10
|
find lib -name "*.rb" | xargs cat | ruby -e "p STDIN.readlines.count { |l| l = l.strip; l[0, 1] != '#' && l != '' }"
|
data/README.md
CHANGED
|
@@ -3,7 +3,6 @@
|
|
|
3
3
|
|
|
4
4
|
[](https://github.com/floraison/et-orbi/actions)
|
|
5
5
|
[](http://badge.fury.io/rb/et-orbi)
|
|
6
|
-
[](https://gitter.im/floraison/fugit?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
|
|
7
6
|
|
|
8
7
|
Time zones for [fugit](https://github.com/floraison/fugit) and for [rufus-scheduler](https://github.com/jmettraux/rufus-scheduler). Urbi et Orbi.
|
|
9
8
|
|
data/lib/et-orbi/time.rb
CHANGED
|
@@ -101,6 +101,8 @@ module EtOrbi
|
|
|
101
101
|
def zone=(z)
|
|
102
102
|
|
|
103
103
|
@time = nil
|
|
104
|
+
@ref = nil
|
|
105
|
+
|
|
104
106
|
@zone = self.class.get_tzone(zone || :current)
|
|
105
107
|
end
|
|
106
108
|
|
|
@@ -330,16 +332,22 @@ module EtOrbi
|
|
|
330
332
|
- count_weeks(EtOrbi.make_time(strftime('%F 12:00:00 %/Z')) , 1) ]
|
|
331
333
|
end
|
|
332
334
|
|
|
335
|
+
# "reference week", used in fugit for cron modulo notation
|
|
336
|
+
#
|
|
333
337
|
def rweek
|
|
334
338
|
|
|
335
|
-
|
|
336
|
-
|
|
339
|
+
@ref ||= EtOrbi.make_time('2019-01-01 00:00:00', @zone)
|
|
340
|
+
|
|
341
|
+
((self - @ref) / WEEK_S).floor + 1
|
|
337
342
|
end
|
|
338
343
|
|
|
344
|
+
# "reference week", used in fugit for cron modulo notation
|
|
345
|
+
#
|
|
339
346
|
def rday
|
|
340
347
|
|
|
341
|
-
|
|
342
|
-
|
|
348
|
+
@ref ||= EtOrbi.make_time('2019-01-01 00:00:00', @zone)
|
|
349
|
+
|
|
350
|
+
((self - @ref) / DAY_S).floor + 1
|
|
343
351
|
end
|
|
344
352
|
|
|
345
353
|
def reach(points)
|
data/lib/et-orbi.rb
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: et-orbi
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.2.
|
|
4
|
+
version: 1.2.8
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- John Mettraux
|
|
8
|
-
autorequire:
|
|
8
|
+
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date:
|
|
11
|
+
date: 2024-03-11 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: tzinfo
|
|
@@ -82,7 +82,7 @@ metadata:
|
|
|
82
82
|
bug_tracker_uri: https://github.com/floraison/et-orbi/issues
|
|
83
83
|
homepage_uri: https://github.com/floraison/et-orbi
|
|
84
84
|
source_code_uri: https://github.com/floraison/et-orbi
|
|
85
|
-
post_install_message:
|
|
85
|
+
post_install_message:
|
|
86
86
|
rdoc_options: []
|
|
87
87
|
require_paths:
|
|
88
88
|
- lib
|
|
@@ -97,8 +97,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
97
97
|
- !ruby/object:Gem::Version
|
|
98
98
|
version: '0'
|
|
99
99
|
requirements: []
|
|
100
|
-
rubygems_version: 3.
|
|
101
|
-
signing_key:
|
|
100
|
+
rubygems_version: 3.2.33
|
|
101
|
+
signing_key:
|
|
102
102
|
specification_version: 4
|
|
103
103
|
summary: time with zones
|
|
104
104
|
test_files: []
|