jess 0.10.0 → 1.1.2
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/LICENSE.txt +1 -1
- data/README.md +3 -4
- data/lib/jess/http_client/error_decorator.rb +0 -2
- data/lib/jess/version.rb +1 -1
- metadata +10 -151
- data/.github/main.workflow +0 -9
- data/.github/pull_request_template.md +0 -6
- data/.github/release-drafter.yml +0 -17
- data/.gitignore +0 -9
- data/.prettierignore +0 -2
- data/.rubocop.yml +0 -57
- data/.travis.yml +0 -13
- data/CHANGELOG.md +0 -1
- data/CODE_OF_CONDUCT.md +0 -74
- data/CONTRIBUTING.md +0 -21
- data/Gemfile +0 -4
- data/Rakefile +0 -106
- data/bin/console +0 -14
- data/bin/setup +0 -8
- data/jess.gemspec +0 -41
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 8c1f2b2768c6dd2b43da546c3a488515b0f8717d13a7542e9ae300be498a21a0
|
|
4
|
+
data.tar.gz: 9017e596dd4f7e9b457474deaca58981e4f338ed5e22c1f041b93274e11cc3c4
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 42c7307ff7ec5840f0a2753cb8ebbf9b6a66c922a2fe619195a341402fcdd899a15fd0aa34df09a7bd2bb5e1cb725b104f921bb0b2928450ddf7206b19905c7b
|
|
7
|
+
data.tar.gz: 2e0764b8579cfc647af0b4732c2f035245ddd165d7db0393cee0cf164aeb7c8a524dab142295ca91809bcdbad508fd8c84d65c57a1be02f17c75244612970121
|
data/LICENSE.txt
CHANGED
data/README.md
CHANGED
|
@@ -1,12 +1,11 @@
|
|
|
1
1
|
# Jess
|
|
2
2
|
|
|
3
3
|
[](http://badge.fury.io/rb/jess)
|
|
4
|
-
[](https://travis-ci.org/mattbrictson/jess)
|
|
5
5
|
[](https://codeclimate.com/github/mattbrictson/jess)
|
|
6
|
-
[](https://coveralls.io/github/mattbrictson/jess?branch=master)
|
|
7
6
|
|
|
8
7
|
**Jess is an extremely lightweight, read-only client for the JAMF Software Server (JSS) API.**
|
|
9
|
-
|
|
8
|
+
Currently it only provides access to computer and mobile device records.
|
|
10
9
|
|
|
11
10
|
Jess aims to be:
|
|
12
11
|
|
|
@@ -32,7 +31,7 @@ Or install it yourself as:
|
|
|
32
31
|
|
|
33
32
|
$ gem install jess
|
|
34
33
|
|
|
35
|
-
*Note that Jess requires Ruby 2.
|
|
34
|
+
*Note that Jess requires Ruby 2.5 or newer.*
|
|
36
35
|
|
|
37
36
|
## Usage
|
|
38
37
|
|
|
@@ -26,7 +26,6 @@ module Jess
|
|
|
26
26
|
raise Error, res.message
|
|
27
27
|
end
|
|
28
28
|
|
|
29
|
-
# rubocop:disable Lint/EmptyWhen
|
|
30
29
|
def handle_exception(err, req, res)
|
|
31
30
|
case err
|
|
32
31
|
when IOError, Timeout::Error
|
|
@@ -40,7 +39,6 @@ module Jess
|
|
|
40
39
|
fill_exception(err, req, res)
|
|
41
40
|
raise err
|
|
42
41
|
end
|
|
43
|
-
# rubocop:enable Lint/EmptyWhen
|
|
44
42
|
|
|
45
43
|
def fill_exception(err, req, res)
|
|
46
44
|
err.uri = req.uri
|
data/lib/jess/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,165 +1,24 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: jess
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version:
|
|
4
|
+
version: 1.1.2
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Matt Brictson
|
|
8
|
-
autorequire:
|
|
8
|
+
autorequire:
|
|
9
9
|
bindir: exe
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date:
|
|
12
|
-
dependencies:
|
|
13
|
-
|
|
14
|
-
name: awesome_print
|
|
15
|
-
requirement: !ruby/object:Gem::Requirement
|
|
16
|
-
requirements:
|
|
17
|
-
- - "~>"
|
|
18
|
-
- !ruby/object:Gem::Version
|
|
19
|
-
version: '1.7'
|
|
20
|
-
type: :development
|
|
21
|
-
prerelease: false
|
|
22
|
-
version_requirements: !ruby/object:Gem::Requirement
|
|
23
|
-
requirements:
|
|
24
|
-
- - "~>"
|
|
25
|
-
- !ruby/object:Gem::Version
|
|
26
|
-
version: '1.7'
|
|
27
|
-
- !ruby/object:Gem::Dependency
|
|
28
|
-
name: bundler
|
|
29
|
-
requirement: !ruby/object:Gem::Requirement
|
|
30
|
-
requirements:
|
|
31
|
-
- - "~>"
|
|
32
|
-
- !ruby/object:Gem::Version
|
|
33
|
-
version: '2.0'
|
|
34
|
-
type: :development
|
|
35
|
-
prerelease: false
|
|
36
|
-
version_requirements: !ruby/object:Gem::Requirement
|
|
37
|
-
requirements:
|
|
38
|
-
- - "~>"
|
|
39
|
-
- !ruby/object:Gem::Version
|
|
40
|
-
version: '2.0'
|
|
41
|
-
- !ruby/object:Gem::Dependency
|
|
42
|
-
name: coveralls
|
|
43
|
-
requirement: !ruby/object:Gem::Requirement
|
|
44
|
-
requirements:
|
|
45
|
-
- - "~>"
|
|
46
|
-
- !ruby/object:Gem::Version
|
|
47
|
-
version: 0.8.15
|
|
48
|
-
type: :development
|
|
49
|
-
prerelease: false
|
|
50
|
-
version_requirements: !ruby/object:Gem::Requirement
|
|
51
|
-
requirements:
|
|
52
|
-
- - "~>"
|
|
53
|
-
- !ruby/object:Gem::Version
|
|
54
|
-
version: 0.8.15
|
|
55
|
-
- !ruby/object:Gem::Dependency
|
|
56
|
-
name: minitest
|
|
57
|
-
requirement: !ruby/object:Gem::Requirement
|
|
58
|
-
requirements:
|
|
59
|
-
- - "~>"
|
|
60
|
-
- !ruby/object:Gem::Version
|
|
61
|
-
version: '5.0'
|
|
62
|
-
type: :development
|
|
63
|
-
prerelease: false
|
|
64
|
-
version_requirements: !ruby/object:Gem::Requirement
|
|
65
|
-
requirements:
|
|
66
|
-
- - "~>"
|
|
67
|
-
- !ruby/object:Gem::Version
|
|
68
|
-
version: '5.0'
|
|
69
|
-
- !ruby/object:Gem::Dependency
|
|
70
|
-
name: minitest-reporters
|
|
71
|
-
requirement: !ruby/object:Gem::Requirement
|
|
72
|
-
requirements:
|
|
73
|
-
- - "~>"
|
|
74
|
-
- !ruby/object:Gem::Version
|
|
75
|
-
version: '1.1'
|
|
76
|
-
type: :development
|
|
77
|
-
prerelease: false
|
|
78
|
-
version_requirements: !ruby/object:Gem::Requirement
|
|
79
|
-
requirements:
|
|
80
|
-
- - "~>"
|
|
81
|
-
- !ruby/object:Gem::Version
|
|
82
|
-
version: '1.1'
|
|
83
|
-
- !ruby/object:Gem::Dependency
|
|
84
|
-
name: rake
|
|
85
|
-
requirement: !ruby/object:Gem::Requirement
|
|
86
|
-
requirements:
|
|
87
|
-
- - "~>"
|
|
88
|
-
- !ruby/object:Gem::Version
|
|
89
|
-
version: '12.0'
|
|
90
|
-
type: :development
|
|
91
|
-
prerelease: false
|
|
92
|
-
version_requirements: !ruby/object:Gem::Requirement
|
|
93
|
-
requirements:
|
|
94
|
-
- - "~>"
|
|
95
|
-
- !ruby/object:Gem::Version
|
|
96
|
-
version: '12.0'
|
|
97
|
-
- !ruby/object:Gem::Dependency
|
|
98
|
-
name: rubocop
|
|
99
|
-
requirement: !ruby/object:Gem::Requirement
|
|
100
|
-
requirements:
|
|
101
|
-
- - '='
|
|
102
|
-
- !ruby/object:Gem::Version
|
|
103
|
-
version: 0.71.0
|
|
104
|
-
type: :development
|
|
105
|
-
prerelease: false
|
|
106
|
-
version_requirements: !ruby/object:Gem::Requirement
|
|
107
|
-
requirements:
|
|
108
|
-
- - '='
|
|
109
|
-
- !ruby/object:Gem::Version
|
|
110
|
-
version: 0.71.0
|
|
111
|
-
- !ruby/object:Gem::Dependency
|
|
112
|
-
name: rubocop-performance
|
|
113
|
-
requirement: !ruby/object:Gem::Requirement
|
|
114
|
-
requirements:
|
|
115
|
-
- - '='
|
|
116
|
-
- !ruby/object:Gem::Version
|
|
117
|
-
version: 1.4.0
|
|
118
|
-
type: :development
|
|
119
|
-
prerelease: false
|
|
120
|
-
version_requirements: !ruby/object:Gem::Requirement
|
|
121
|
-
requirements:
|
|
122
|
-
- - '='
|
|
123
|
-
- !ruby/object:Gem::Version
|
|
124
|
-
version: 1.4.0
|
|
125
|
-
- !ruby/object:Gem::Dependency
|
|
126
|
-
name: webmock
|
|
127
|
-
requirement: !ruby/object:Gem::Requirement
|
|
128
|
-
requirements:
|
|
129
|
-
- - "~>"
|
|
130
|
-
- !ruby/object:Gem::Version
|
|
131
|
-
version: '3.1'
|
|
132
|
-
type: :development
|
|
133
|
-
prerelease: false
|
|
134
|
-
version_requirements: !ruby/object:Gem::Requirement
|
|
135
|
-
requirements:
|
|
136
|
-
- - "~>"
|
|
137
|
-
- !ruby/object:Gem::Version
|
|
138
|
-
version: '3.1'
|
|
139
|
-
description:
|
|
11
|
+
date: 2020-11-04 00:00:00.000000000 Z
|
|
12
|
+
dependencies: []
|
|
13
|
+
description:
|
|
140
14
|
email:
|
|
141
15
|
- opensource@mattbrictson.com
|
|
142
16
|
executables: []
|
|
143
17
|
extensions: []
|
|
144
18
|
extra_rdoc_files: []
|
|
145
19
|
files:
|
|
146
|
-
- ".github/main.workflow"
|
|
147
|
-
- ".github/pull_request_template.md"
|
|
148
|
-
- ".github/release-drafter.yml"
|
|
149
|
-
- ".gitignore"
|
|
150
|
-
- ".prettierignore"
|
|
151
|
-
- ".rubocop.yml"
|
|
152
|
-
- ".travis.yml"
|
|
153
|
-
- CHANGELOG.md
|
|
154
|
-
- CODE_OF_CONDUCT.md
|
|
155
|
-
- CONTRIBUTING.md
|
|
156
|
-
- Gemfile
|
|
157
20
|
- LICENSE.txt
|
|
158
21
|
- README.md
|
|
159
|
-
- Rakefile
|
|
160
|
-
- bin/console
|
|
161
|
-
- bin/setup
|
|
162
|
-
- jess.gemspec
|
|
163
22
|
- lib/jess.rb
|
|
164
23
|
- lib/jess/computer.rb
|
|
165
24
|
- lib/jess/computers.rb
|
|
@@ -178,10 +37,10 @@ licenses:
|
|
|
178
37
|
- MIT
|
|
179
38
|
metadata:
|
|
180
39
|
homepage_uri: https://github.com/mattbrictson/jess
|
|
181
|
-
changelog_uri: https://github.com/mattbrictson/jess/
|
|
40
|
+
changelog_uri: https://github.com/mattbrictson/jess/releases
|
|
182
41
|
source_code_uri: https://github.com/mattbrictson/jess/
|
|
183
42
|
bug_tracker_uri: https://github.com/mattbrictson/jess/issues
|
|
184
|
-
post_install_message:
|
|
43
|
+
post_install_message:
|
|
185
44
|
rdoc_options: []
|
|
186
45
|
require_paths:
|
|
187
46
|
- lib
|
|
@@ -189,15 +48,15 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
|
189
48
|
requirements:
|
|
190
49
|
- - ">="
|
|
191
50
|
- !ruby/object:Gem::Version
|
|
192
|
-
version: 2.
|
|
51
|
+
version: 2.5.0
|
|
193
52
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
194
53
|
requirements:
|
|
195
54
|
- - ">="
|
|
196
55
|
- !ruby/object:Gem::Version
|
|
197
56
|
version: '0'
|
|
198
57
|
requirements: []
|
|
199
|
-
rubygems_version: 3.
|
|
200
|
-
signing_key:
|
|
58
|
+
rubygems_version: 3.1.4
|
|
59
|
+
signing_key:
|
|
201
60
|
specification_version: 4
|
|
202
61
|
summary: Lightweight, unofficial client for the JAMF Software Server (JSS) API
|
|
203
62
|
test_files: []
|
data/.github/main.workflow
DELETED
data/.github/release-drafter.yml
DELETED
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
name-template: "$NEXT_PATCH_VERSION"
|
|
2
|
-
tag-template: "v$NEXT_PATCH_VERSION"
|
|
3
|
-
categories:
|
|
4
|
-
- title: "⚠️ Breaking Changes"
|
|
5
|
-
label: "⚠️ Breaking"
|
|
6
|
-
- title: "✨ New Features"
|
|
7
|
-
label: "✨ Feature"
|
|
8
|
-
- title: "🐛 Bug Fixes"
|
|
9
|
-
label: "🐛 Bug Fix"
|
|
10
|
-
- title: "📚 Documentation"
|
|
11
|
-
label: "📚 Docs"
|
|
12
|
-
- title: "🏠 Housekeeping"
|
|
13
|
-
label: "🏠 Housekeeping"
|
|
14
|
-
change-template: "- $TITLE (#$NUMBER) @$AUTHOR"
|
|
15
|
-
no-changes-template: "- No changes"
|
|
16
|
-
template: |
|
|
17
|
-
$CHANGES
|
data/.gitignore
DELETED
data/.prettierignore
DELETED
data/.rubocop.yml
DELETED
|
@@ -1,57 +0,0 @@
|
|
|
1
|
-
require:
|
|
2
|
-
- rubocop-performance
|
|
3
|
-
|
|
4
|
-
AllCops:
|
|
5
|
-
DisplayCopNames: true
|
|
6
|
-
DisplayStyleGuide: true
|
|
7
|
-
TargetRubyVersion: 2.4
|
|
8
|
-
|
|
9
|
-
Layout/SpaceAroundEqualsInParameterDefault:
|
|
10
|
-
EnforcedStyle: no_space
|
|
11
|
-
|
|
12
|
-
Metrics/AbcSize:
|
|
13
|
-
Exclude:
|
|
14
|
-
- "test/**/*"
|
|
15
|
-
|
|
16
|
-
Metrics/BlockLength:
|
|
17
|
-
Exclude:
|
|
18
|
-
- "*.gemspec"
|
|
19
|
-
- "Rakefile"
|
|
20
|
-
|
|
21
|
-
Metrics/ClassLength:
|
|
22
|
-
Exclude:
|
|
23
|
-
- "test/**/*"
|
|
24
|
-
|
|
25
|
-
Metrics/LineLength:
|
|
26
|
-
Exclude:
|
|
27
|
-
- "*.gemspec"
|
|
28
|
-
|
|
29
|
-
Metrics/MethodLength:
|
|
30
|
-
Exclude:
|
|
31
|
-
- "test/**/*"
|
|
32
|
-
|
|
33
|
-
Naming/MemoizedInstanceVariableName:
|
|
34
|
-
Enabled: false
|
|
35
|
-
|
|
36
|
-
Style/BarePercentLiterals:
|
|
37
|
-
EnforcedStyle: percent_q
|
|
38
|
-
|
|
39
|
-
Style/ClassAndModuleChildren:
|
|
40
|
-
Enabled: false
|
|
41
|
-
|
|
42
|
-
Style/Documentation:
|
|
43
|
-
Exclude:
|
|
44
|
-
- "Rakefile"
|
|
45
|
-
- 'test/**/*'
|
|
46
|
-
|
|
47
|
-
Style/DoubleNegation:
|
|
48
|
-
Enabled: false
|
|
49
|
-
|
|
50
|
-
Style/FrozenStringLiteralComment:
|
|
51
|
-
Enabled: false
|
|
52
|
-
|
|
53
|
-
Style/StringLiterals:
|
|
54
|
-
EnforcedStyle: double_quotes
|
|
55
|
-
|
|
56
|
-
Style/TrivialAccessors:
|
|
57
|
-
AllowPredicates: true
|
data/.travis.yml
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
sudo: false
|
|
3
|
-
language: ruby
|
|
4
|
-
cache: bundler
|
|
5
|
-
rvm:
|
|
6
|
-
- 2.4.6
|
|
7
|
-
- 2.5.5
|
|
8
|
-
- 2.6.3
|
|
9
|
-
- ruby-head
|
|
10
|
-
before_install:
|
|
11
|
-
- gem update --system
|
|
12
|
-
- gem install bundler -v 2.0.2 --conservative --no-document
|
|
13
|
-
- gem install executable-hooks --conservative --no-document
|
data/CHANGELOG.md
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
Release notes for this project are kept here: https://github.com/mattbrictson/jess/releases
|
data/CODE_OF_CONDUCT.md
DELETED
|
@@ -1,74 +0,0 @@
|
|
|
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 matt@mattbrictson.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/CONTRIBUTING.md
DELETED
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
# Contributing to Jess
|
|
2
|
-
|
|
3
|
-
Have a feature idea, bug fix, or refactoring suggestion? Contributions are welcome! Here are some general guidelines.
|
|
4
|
-
|
|
5
|
-
## Discuss first!
|
|
6
|
-
|
|
7
|
-
1. Check [Issues][] to see if your contribution has already been discussed and/or implemented.
|
|
8
|
-
2. If not, open an issue to discuss your contribution. I won't accept all changes and do not want to waste your time.
|
|
9
|
-
3. Once you have the :thumbsup:, fork the repo, make your changes, and open a PR.
|
|
10
|
-
|
|
11
|
-
## Before you commit
|
|
12
|
-
|
|
13
|
-
* Did you add tests? New features or changes in behavior should be tested.
|
|
14
|
-
* Do all tests and RuboCop checks pass? Run `bundle exec rake` to be sure.
|
|
15
|
-
* Did you add a CHANGELOG entry? All non-trivial PRs need one.
|
|
16
|
-
|
|
17
|
-
## Questions?
|
|
18
|
-
|
|
19
|
-
Need help writing an appropriate test? Not sure the best way to attack a problem? Please ask by [posting a GitHub issue][Issues]!
|
|
20
|
-
|
|
21
|
-
[Issues]: https://github.com/mattbrictson/jess/issues
|
data/Gemfile
DELETED
data/Rakefile
DELETED
|
@@ -1,106 +0,0 @@
|
|
|
1
|
-
require "bundler/gem_tasks"
|
|
2
|
-
require "rake/testtask"
|
|
3
|
-
require "rubocop/rake_task"
|
|
4
|
-
|
|
5
|
-
Rake::TestTask.new(:test) do |t|
|
|
6
|
-
t.libs << "test"
|
|
7
|
-
t.libs << "lib"
|
|
8
|
-
t.test_files = FileList["test/**/*_test.rb"]
|
|
9
|
-
end
|
|
10
|
-
|
|
11
|
-
RuboCop::RakeTask.new
|
|
12
|
-
|
|
13
|
-
task default: %i[test rubocop]
|
|
14
|
-
|
|
15
|
-
Rake::Task["release"].enhance do
|
|
16
|
-
puts "Don't forget to publish the release on GitHub!"
|
|
17
|
-
system "open https://github.com/mattbrictson/jess/releases"
|
|
18
|
-
end
|
|
19
|
-
|
|
20
|
-
task bump: %w[bump:bundler bump:ruby bump:year]
|
|
21
|
-
|
|
22
|
-
namespace :bump do
|
|
23
|
-
task :bundler do
|
|
24
|
-
version = Gemfile.bundler_version
|
|
25
|
-
replace_in_file ".travis.yml", /bundler -v (\S+)/ => version
|
|
26
|
-
end
|
|
27
|
-
|
|
28
|
-
task :ruby do
|
|
29
|
-
lowest = RubyVersions.lowest_supported
|
|
30
|
-
lowest_minor = RubyVersions.lowest_supported_minor
|
|
31
|
-
|
|
32
|
-
replace_in_file "jess.gemspec", /ruby_version = ">= (.*)"/ => lowest
|
|
33
|
-
replace_in_file ".rubocop.yml", /TargetRubyVersion: (.*)/ => lowest_minor
|
|
34
|
-
replace_in_file "README.md", /requires Ruby (\d\.\d)/i => lowest_minor
|
|
35
|
-
|
|
36
|
-
travis = YAML.safe_load(open(".travis.yml"))
|
|
37
|
-
travis["rvm"] = RubyVersions.latest_supported_patches + ["ruby-head"]
|
|
38
|
-
IO.write(".travis.yml", YAML.dump(travis))
|
|
39
|
-
end
|
|
40
|
-
|
|
41
|
-
task :year do
|
|
42
|
-
replace_in_file "LICENSE.txt", /\(c\) (\d+)/ => Date.today.year.to_s
|
|
43
|
-
end
|
|
44
|
-
end
|
|
45
|
-
|
|
46
|
-
require "date"
|
|
47
|
-
require "open-uri"
|
|
48
|
-
require "yaml"
|
|
49
|
-
|
|
50
|
-
def replace_in_file(path, replacements)
|
|
51
|
-
contents = IO.read(path)
|
|
52
|
-
orig_contents = contents.dup
|
|
53
|
-
replacements.each do |regexp, text|
|
|
54
|
-
contents.gsub!(regexp) do |match|
|
|
55
|
-
match[regexp, 1] = text
|
|
56
|
-
match
|
|
57
|
-
end
|
|
58
|
-
end
|
|
59
|
-
IO.write(path, contents) if contents != orig_contents
|
|
60
|
-
end
|
|
61
|
-
|
|
62
|
-
module Gemfile
|
|
63
|
-
class << self
|
|
64
|
-
def bundler_version
|
|
65
|
-
lock_file[/BUNDLED WITH\n (\S+)$/, 1]
|
|
66
|
-
end
|
|
67
|
-
|
|
68
|
-
private
|
|
69
|
-
|
|
70
|
-
def lock_file
|
|
71
|
-
@_lock_file ||= IO.read("Gemfile.lock")
|
|
72
|
-
end
|
|
73
|
-
end
|
|
74
|
-
end
|
|
75
|
-
|
|
76
|
-
module RubyVersions
|
|
77
|
-
class << self
|
|
78
|
-
def lowest_supported
|
|
79
|
-
"#{lowest_supported_minor}.0"
|
|
80
|
-
end
|
|
81
|
-
|
|
82
|
-
def lowest_supported_minor
|
|
83
|
-
latest_supported_patches.first[/\d+\.\d+/]
|
|
84
|
-
end
|
|
85
|
-
|
|
86
|
-
def latest
|
|
87
|
-
latest_supported_patches.last
|
|
88
|
-
end
|
|
89
|
-
|
|
90
|
-
def latest_supported_patches
|
|
91
|
-
patches = [versions[:stable], versions[:security_maintenance]].flatten
|
|
92
|
-
patches.map(&Gem::Version.method(:new)).sort.map(&:to_s)
|
|
93
|
-
end
|
|
94
|
-
|
|
95
|
-
private
|
|
96
|
-
|
|
97
|
-
def versions
|
|
98
|
-
@_versions ||= begin
|
|
99
|
-
yaml = open(
|
|
100
|
-
"https://raw.githubusercontent.com/ruby/www.ruby-lang.org/master/_data/downloads.yml"
|
|
101
|
-
)
|
|
102
|
-
YAML.safe_load(yaml, symbolize_names: true)
|
|
103
|
-
end
|
|
104
|
-
end
|
|
105
|
-
end
|
|
106
|
-
end
|
data/bin/console
DELETED
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env ruby
|
|
2
|
-
|
|
3
|
-
require "bundler/setup"
|
|
4
|
-
require "jess"
|
|
5
|
-
|
|
6
|
-
# You can add fixtures and/or initialization code here to make experimenting
|
|
7
|
-
# with your gem easier. You can also use a different console, if you like.
|
|
8
|
-
|
|
9
|
-
# (If you use this, don't forget to add pry to your Gemfile!)
|
|
10
|
-
# require "pry"
|
|
11
|
-
# Pry.start
|
|
12
|
-
|
|
13
|
-
require "irb"
|
|
14
|
-
IRB.start(__FILE__)
|
data/bin/setup
DELETED
data/jess.gemspec
DELETED
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
lib = File.expand_path("lib", __dir__)
|
|
2
|
-
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
|
3
|
-
require "jess/version"
|
|
4
|
-
|
|
5
|
-
Gem::Specification.new do |spec|
|
|
6
|
-
spec.name = "jess"
|
|
7
|
-
spec.version = Jess::VERSION
|
|
8
|
-
spec.authors = ["Matt Brictson"]
|
|
9
|
-
spec.email = ["opensource@mattbrictson.com"]
|
|
10
|
-
|
|
11
|
-
spec.summary = "Lightweight, unofficial client for the JAMF Software "\
|
|
12
|
-
"Server (JSS) API"
|
|
13
|
-
spec.homepage = "https://github.com/mattbrictson/jess"
|
|
14
|
-
spec.license = "MIT"
|
|
15
|
-
|
|
16
|
-
spec.metadata = {
|
|
17
|
-
"homepage_uri" => "https://github.com/mattbrictson/jess",
|
|
18
|
-
"changelog_uri" => "https://github.com/mattbrictson/jess/blob/master/CHANGELOG.md",
|
|
19
|
-
"source_code_uri" => "https://github.com/mattbrictson/jess/",
|
|
20
|
-
"bug_tracker_uri" => "https://github.com/mattbrictson/jess/issues"
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
spec.files = `git ls-files -z`.split("\x0").reject do |f|
|
|
24
|
-
f.match(%r{^(test|spec|features)/})
|
|
25
|
-
end
|
|
26
|
-
spec.bindir = "exe"
|
|
27
|
-
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
|
28
|
-
spec.require_paths = ["lib"]
|
|
29
|
-
|
|
30
|
-
spec.required_ruby_version = ">= 2.4.0"
|
|
31
|
-
|
|
32
|
-
spec.add_development_dependency "awesome_print", "~> 1.7"
|
|
33
|
-
spec.add_development_dependency "bundler", "~> 2.0"
|
|
34
|
-
spec.add_development_dependency "coveralls", "~> 0.8.15"
|
|
35
|
-
spec.add_development_dependency "minitest", "~> 5.0"
|
|
36
|
-
spec.add_development_dependency "minitest-reporters", "~>1.1"
|
|
37
|
-
spec.add_development_dependency "rake", "~> 12.0"
|
|
38
|
-
spec.add_development_dependency "rubocop", "= 0.71.0"
|
|
39
|
-
spec.add_development_dependency "rubocop-performance", "= 1.4.0"
|
|
40
|
-
spec.add_development_dependency "webmock", "~> 3.1"
|
|
41
|
-
end
|