lastpassify 0.4.1 → 0.4.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/.gitignore +1 -0
- data/.reek.yml +23 -0
- data/.ruby-version +1 -1
- data/.standard.yml +9 -0
- data/Brewfile +1 -0
- data/Gemfile.lock +109 -78
- data/LICENSE +21 -0
- data/README.md +1 -1
- data/changelog.md +16 -0
- data/lastpassify.gemspec +16 -17
- data/lib/lastpassify/lastpassify.rb +7 -7
- data/lib/lastpassify/runner.rb +3 -3
- data/lib/lastpassify/version.rb +1 -1
- data/script/autoformat +12 -0
- data/script/bootstrap +5 -11
- data/script/hooks/pre-commit +5 -0
- data/script/lint +14 -0
- data/script/setup +7 -0
- metadata +22 -23
- data/.overcommit.yml +0 -17
- data/.reek +0 -10
- data/bin/lastpassify +0 -7
- data/bin/reek +0 -17
- data/bin/rubocop +0 -17
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: c8fa2651a40480bf59970d5803e13b9260b3b733c9573bf00a3079a675d4d5bf
|
4
|
+
data.tar.gz: 7014f3ec1ca55b372e8286a39d73907ecaaac3eb62530f0e7689ea763378bfc2
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a9bed41890c2a2a41366a5ea63b34ec59d7c1207c8c1876ff99a213e2e81a7c842f041140062234c574eab99b266ef25072517d18b8ccb48e9c95b86b52c019b
|
7
|
+
data.tar.gz: eb17d7bb573a52c5decb520e7fd6c3096afca4744c13b4e599942503a85c467b3363c2047de4152449c388fcba23b3dfed21f4707d6089d7d571924972d6e79b
|
data/.gitignore
CHANGED
data/.reek.yml
ADDED
@@ -0,0 +1,23 @@
|
|
1
|
+
---
|
2
|
+
detectors:
|
3
|
+
IrresponsibleModule:
|
4
|
+
exclude:
|
5
|
+
- LastPassify::Runner
|
6
|
+
MissingSafeMethod:
|
7
|
+
exclude:
|
8
|
+
- LastPassify::Runner
|
9
|
+
TooManyInstanceVariables:
|
10
|
+
exclude:
|
11
|
+
- LastPassify::Runner
|
12
|
+
TooManyStatements:
|
13
|
+
enabled: true
|
14
|
+
max_statements: 7
|
15
|
+
exclude:
|
16
|
+
- LastPassify::Runner#execute!
|
17
|
+
UtilityFunction:
|
18
|
+
public_methods_only: true
|
19
|
+
UncommunicativeVariableName:
|
20
|
+
exclude:
|
21
|
+
- LastPassify::Runner#execute!
|
22
|
+
exclude_paths:
|
23
|
+
- bundle
|
data/.ruby-version
CHANGED
@@ -1 +1 @@
|
|
1
|
-
2.
|
1
|
+
2.7.1
|
data/.standard.yml
ADDED
data/Brewfile
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
brew "lastpass-cli"
|
data/Gemfile.lock
CHANGED
@@ -1,97 +1,128 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
lastpassify (0.4.
|
4
|
+
lastpassify (0.4.2)
|
5
5
|
thor
|
6
6
|
|
7
7
|
GEM
|
8
8
|
remote: https://rubygems.org/
|
9
9
|
specs:
|
10
|
-
|
11
|
-
|
10
|
+
activesupport (5.2.4.4)
|
11
|
+
concurrent-ruby (~> 1.0, >= 1.0.2)
|
12
|
+
i18n (>= 0.7, < 2)
|
13
|
+
minitest (~> 5.1)
|
14
|
+
tzinfo (~> 1.1)
|
15
|
+
aruba (0.14.14)
|
16
|
+
childprocess (>= 0.6.3, < 4.0.0)
|
12
17
|
contracts (~> 0.9)
|
13
18
|
cucumber (>= 1.3.19)
|
14
|
-
ffi (~> 1.9
|
19
|
+
ffi (~> 1.9)
|
15
20
|
rspec-expectations (>= 2.99)
|
16
|
-
thor (
|
17
|
-
ast (2.
|
21
|
+
thor (>= 0.19, < 2.0)
|
22
|
+
ast (2.4.1)
|
18
23
|
awesome_print (1.8.0)
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
ffi (~> 1.0, >= 1.0.11)
|
26
|
-
codeclimate-engine-rb (0.4.0)
|
27
|
-
virtus (~> 1.0)
|
28
|
-
coercible (1.0.0)
|
29
|
-
descendants_tracker (~> 0.0.1)
|
24
|
+
builder (3.2.4)
|
25
|
+
bundler-audit (0.7.0.1)
|
26
|
+
bundler (>= 1.2.0, < 3)
|
27
|
+
thor (>= 0.18, < 2)
|
28
|
+
childprocess (3.0.0)
|
29
|
+
concurrent-ruby (1.1.8)
|
30
30
|
contracts (0.16.0)
|
31
|
-
cucumber (
|
32
|
-
builder (>= 2.
|
33
|
-
cucumber-core (~> 1.
|
34
|
-
cucumber-
|
35
|
-
|
36
|
-
gherkin (~>
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
31
|
+
cucumber (4.1.0)
|
32
|
+
builder (~> 3.2, >= 3.2.3)
|
33
|
+
cucumber-core (~> 7.1, >= 7.1.0)
|
34
|
+
cucumber-create-meta (~> 1.0.0, >= 1.0.0)
|
35
|
+
cucumber-cucumber-expressions (~> 10.1, >= 10.1.0)
|
36
|
+
cucumber-gherkin (~> 14.0, >= 14.0.1)
|
37
|
+
cucumber-html-formatter (~> 7.0, >= 7.0.0)
|
38
|
+
cucumber-messages (~> 12.2, >= 12.2.0)
|
39
|
+
cucumber-wire (~> 3.1, >= 3.1.0)
|
40
|
+
diff-lcs (~> 1.3, >= 1.3, < 1.4)
|
41
|
+
multi_test (~> 0.1, >= 0.1.2)
|
42
|
+
sys-uname (~> 1.0, >= 1.0.2)
|
43
|
+
cucumber-core (7.1.0)
|
44
|
+
cucumber-gherkin (~> 14.0, >= 14.0.1)
|
45
|
+
cucumber-messages (~> 12.2, >= 12.2.0)
|
46
|
+
cucumber-tag-expressions (~> 2.0, >= 2.0.4)
|
47
|
+
cucumber-create-meta (1.0.0)
|
48
|
+
cucumber-messages (~> 12.2, >= 12.2.0)
|
49
|
+
sys-uname (~> 1.2, >= 1.2.1)
|
50
|
+
cucumber-cucumber-expressions (10.3.0)
|
51
|
+
cucumber-gherkin (14.2.0)
|
52
|
+
cucumber-messages (~> 12.4, >= 12.4.0)
|
53
|
+
cucumber-html-formatter (7.2.0)
|
54
|
+
cucumber-messages (~> 12.4, >= 12.4.0)
|
55
|
+
cucumber-messages (12.4.0)
|
56
|
+
protobuf-cucumber (~> 3.10, >= 3.10.8)
|
57
|
+
cucumber-tag-expressions (2.0.4)
|
58
|
+
cucumber-wire (3.1.0)
|
59
|
+
cucumber-core (~> 7.1, >= 7.1.0)
|
60
|
+
cucumber-cucumber-expressions (~> 10.1, >= 10.1.0)
|
61
|
+
cucumber-messages (~> 12.2, >= 12.2.0)
|
44
62
|
diff-lcs (1.3)
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
63
|
+
ffi (1.14.2)
|
64
|
+
i18n (1.8.7)
|
65
|
+
concurrent-ruby (~> 1.0)
|
66
|
+
kwalify (0.7.2)
|
67
|
+
middleware (0.1.0)
|
68
|
+
minitest (5.14.3)
|
51
69
|
multi_test (0.1.2)
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
rspec
|
71
|
-
rspec-
|
72
|
-
|
70
|
+
parallel (1.20.1)
|
71
|
+
parser (3.0.0.0)
|
72
|
+
ast (~> 2.4.1)
|
73
|
+
protobuf-cucumber (3.10.8)
|
74
|
+
activesupport (>= 3.2)
|
75
|
+
middleware
|
76
|
+
thor
|
77
|
+
thread_safe
|
78
|
+
psych (3.3.0)
|
79
|
+
rainbow (3.0.0)
|
80
|
+
rake (13.0.3)
|
81
|
+
reek (6.0.3)
|
82
|
+
kwalify (~> 0.7.0)
|
83
|
+
parser (~> 3.0.0)
|
84
|
+
psych (~> 3.1)
|
85
|
+
rainbow (>= 2.0, < 4.0)
|
86
|
+
regexp_parser (2.0.3)
|
87
|
+
rexml (3.2.4)
|
88
|
+
rspec (3.10.0)
|
89
|
+
rspec-core (~> 3.10.0)
|
90
|
+
rspec-expectations (~> 3.10.0)
|
91
|
+
rspec-mocks (~> 3.10.0)
|
92
|
+
rspec-core (3.10.1)
|
93
|
+
rspec-support (~> 3.10.0)
|
94
|
+
rspec-expectations (3.10.1)
|
73
95
|
diff-lcs (>= 1.2.0, < 2.0)
|
74
|
-
rspec-support (~> 3.
|
75
|
-
rspec-mocks (3.
|
96
|
+
rspec-support (~> 3.10.0)
|
97
|
+
rspec-mocks (3.10.1)
|
76
98
|
diff-lcs (>= 1.2.0, < 2.0)
|
77
|
-
rspec-support (~> 3.
|
78
|
-
rspec-support (3.
|
79
|
-
rubocop (
|
99
|
+
rspec-support (~> 3.10.0)
|
100
|
+
rspec-support (3.10.1)
|
101
|
+
rubocop (1.7.0)
|
80
102
|
parallel (~> 1.10)
|
81
|
-
parser (>= 2.
|
82
|
-
|
83
|
-
|
103
|
+
parser (>= 2.7.1.5)
|
104
|
+
rainbow (>= 2.2.2, < 4.0)
|
105
|
+
regexp_parser (>= 1.8, < 3.0)
|
106
|
+
rexml
|
107
|
+
rubocop-ast (>= 1.2.0, < 2.0)
|
84
108
|
ruby-progressbar (~> 1.7)
|
85
|
-
unicode-display_width (
|
86
|
-
|
87
|
-
|
109
|
+
unicode-display_width (>= 1.4.0, < 2.0)
|
110
|
+
rubocop-ast (1.4.0)
|
111
|
+
parser (>= 2.7.1.5)
|
112
|
+
rubocop-performance (1.9.2)
|
113
|
+
rubocop (>= 0.90.0, < 2.0)
|
114
|
+
rubocop-ast (>= 0.4.0)
|
115
|
+
ruby-progressbar (1.11.0)
|
116
|
+
standard (0.11.0)
|
117
|
+
rubocop (= 1.7.0)
|
118
|
+
rubocop-performance (= 1.9.2)
|
119
|
+
sys-uname (1.2.2)
|
120
|
+
ffi (~> 1.1)
|
121
|
+
thor (1.1.0)
|
88
122
|
thread_safe (0.3.6)
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
coercible (~> 1.0)
|
93
|
-
descendants_tracker (~> 0.0, >= 0.0.3)
|
94
|
-
equalizer (~> 0.0, >= 0.0.9)
|
123
|
+
tzinfo (1.2.9)
|
124
|
+
thread_safe (~> 0.1)
|
125
|
+
unicode-display_width (1.7.0)
|
95
126
|
|
96
127
|
PLATFORMS
|
97
128
|
ruby
|
@@ -99,13 +130,13 @@ PLATFORMS
|
|
99
130
|
DEPENDENCIES
|
100
131
|
aruba (~> 0.14.2)
|
101
132
|
awesome_print
|
102
|
-
bundler (~>
|
133
|
+
bundler (~> 2.0)
|
134
|
+
bundler-audit
|
103
135
|
lastpassify!
|
104
|
-
overcommit
|
105
136
|
rake
|
106
137
|
reek
|
107
138
|
rspec
|
108
|
-
|
139
|
+
standard
|
109
140
|
|
110
141
|
BUNDLED WITH
|
111
|
-
|
142
|
+
2.2.6
|
data/LICENSE
ADDED
@@ -0,0 +1,21 @@
|
|
1
|
+
MIT License
|
2
|
+
|
3
|
+
Copyright (c) 2018 ASR Custom Solutions
|
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.
|
data/README.md
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
# LastPassify
|
2
2
|
|
3
|
-
LastPassify is a gem for automating `database.yml` configuration files. The goal of this gem is to populate a given a YAML ERB config file with values from LastPass. It uses the Ruby toolkit [Thor](https://github.com/erikhuda/thor) and [lastpass-cli](https://github.com/lastpass/lastpass-cli).
|
3
|
+
[![Gem Version](https://badge.fury.io/rb/lastpassify.svg)](https://badge.fury.io/rb/lastpassify) LastPassify is a gem for automating `database.yml` configuration files. The goal of this gem is to populate a given a YAML ERB config file with values from LastPass. It uses the Ruby toolkit [Thor](https://github.com/erikhuda/thor) and [lastpass-cli](https://github.com/lastpass/lastpass-cli).
|
4
4
|
|
5
5
|
### Install
|
6
6
|
|
data/changelog.md
ADDED
@@ -0,0 +1,16 @@
|
|
1
|
+
# Changelog
|
2
|
+
All notable changes to this project will be documented in this file.
|
3
|
+
|
4
|
+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
5
|
+
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
6
|
+
|
7
|
+
## [Unreleased]
|
8
|
+
|
9
|
+
## [0.4.2]
|
10
|
+
|
11
|
+
- Updates to dependencies
|
12
|
+
- Minimum Ruby version is now 2.3
|
13
|
+
- Hopefully fixing the binstub warning
|
14
|
+
|
15
|
+
[Unreleased]: https://github.com/umn-asr/lastpassify/compare/v0.4.2...HEAD
|
16
|
+
[0.4.2]: https://github.com/umn-asr/lastpassify/compare/3997abac1101eb75c91543241651976be4d49f73...HEAD
|
data/lastpassify.gemspec
CHANGED
@@ -1,32 +1,31 @@
|
|
1
|
-
|
2
|
-
lib = File.expand_path('../lib', __FILE__)
|
1
|
+
lib = File.expand_path("../lib", __FILE__)
|
3
2
|
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
4
|
-
require
|
3
|
+
require "lastpassify/version"
|
5
4
|
|
6
5
|
Gem::Specification.new do |spec|
|
7
|
-
spec.name
|
8
|
-
spec.version
|
9
|
-
spec.authors
|
10
|
-
spec.email
|
6
|
+
spec.name = "lastpassify"
|
7
|
+
spec.version = LastPassify::VERSION
|
8
|
+
spec.authors = ["Eric Eklund (eeklund), Remy Abdullahi (abdu0299)"]
|
9
|
+
spec.email = ["eeklund@umn.edu", "abdu0299@umn.edu"]
|
11
10
|
|
12
|
-
spec.summary
|
13
|
-
spec.description
|
14
|
-
spec.homepage
|
15
|
-
spec.license
|
11
|
+
spec.summary = "Populate ERB file with values from LastPass"
|
12
|
+
spec.description = "This gem populates a given ERB/YAML file with values from LastPass using LastPass-CLI."
|
13
|
+
spec.homepage = "https://github.com/umn-asr/lastpassify"
|
14
|
+
spec.license = "MIT"
|
16
15
|
|
17
|
-
spec.files
|
16
|
+
spec.files = `git ls-files -z`.split("\x0").reject do |f|
|
18
17
|
f.match(%r{^(test|spec|features)/})
|
19
18
|
end
|
20
|
-
spec.executables
|
19
|
+
spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
|
21
20
|
spec.require_paths = ["lib"]
|
22
21
|
|
23
|
-
spec.required_ruby_version = ">= 2.
|
22
|
+
spec.required_ruby_version = ">= 2.3.0"
|
24
23
|
|
25
|
-
spec.add_development_dependency "bundler", "~>
|
24
|
+
spec.add_development_dependency "bundler", "~> 2.0"
|
25
|
+
spec.add_development_dependency "bundler-audit"
|
26
26
|
spec.add_development_dependency "rake"
|
27
|
-
spec.add_development_dependency "
|
27
|
+
spec.add_development_dependency "standard"
|
28
28
|
spec.add_development_dependency "reek"
|
29
|
-
spec.add_development_dependency "overcommit"
|
30
29
|
spec.add_development_dependency "awesome_print"
|
31
30
|
spec.add_development_dependency "aruba", "~> 0.14.2"
|
32
31
|
spec.add_development_dependency "rspec"
|
@@ -22,7 +22,7 @@ module LastPassify
|
|
22
22
|
|
23
23
|
desc "Takes a file to process, and outputs a new file populated with values from LastPass."
|
24
24
|
|
25
|
-
NOW = Time.now.strftime(
|
25
|
+
NOW = Time.now.strftime("%v")
|
26
26
|
|
27
27
|
def main
|
28
28
|
raise LPassNotInstalled, "Please install LastPass-CLI - https://github.com/lastpass/lastpass-cli" unless lastpass_installed?
|
@@ -39,10 +39,10 @@ module LastPassify
|
|
39
39
|
no_commands do
|
40
40
|
def lookup(_source, shared_path, field)
|
41
41
|
response = if %w[username password url notes id name].include? field
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
42
|
+
`lpass show --#{field} "#{shared_path}"`.chomp
|
43
|
+
else
|
44
|
+
`lpass show --field='#{field}' "#{shared_path}"`.chomp
|
45
|
+
end
|
46
46
|
|
47
47
|
puts "Please fill in: '#{shared_path}' : #{field} field" if response.empty?
|
48
48
|
|
@@ -58,13 +58,13 @@ module LastPassify
|
|
58
58
|
|
59
59
|
def delete_staging(yml)
|
60
60
|
yml.keys.each do |key|
|
61
|
-
yml.delete(key) if
|
61
|
+
yml.delete(key) if /staging|qat/.match?(key.to_s)
|
62
62
|
end
|
63
63
|
end
|
64
64
|
|
65
65
|
def delete_production(yml)
|
66
66
|
yml.keys.each do |key|
|
67
|
-
yml.delete(key) if key.to_s
|
67
|
+
yml.delete(key) if /production/.match?(key.to_s)
|
68
68
|
end
|
69
69
|
end
|
70
70
|
end
|
data/lib/lastpassify/runner.rb
CHANGED
@@ -3,7 +3,7 @@ require "lastpassify/lastpassify"
|
|
3
3
|
module LastPassify
|
4
4
|
class Runner
|
5
5
|
# Allow everything fun to be injected from the outside while defaulting to normal implementations.
|
6
|
-
def initialize(argv, stdin =
|
6
|
+
def initialize(argv, stdin = $stdin, stdout = $stdout, stderr = $stderr, kernel = Kernel)
|
7
7
|
@argv, @stdin, @stdout, @stderr, @kernel = argv, stdin, stdout, stderr, kernel
|
8
8
|
end
|
9
9
|
|
@@ -19,11 +19,11 @@ module LastPassify
|
|
19
19
|
|
20
20
|
# Thor::Base#start does not have a return value, assume success if no exception is raised.
|
21
21
|
0
|
22
|
-
rescue
|
22
|
+
rescue => e
|
23
23
|
# The ruby interpreter would pipe this to STDERR and exit 1 in the case of an unhandled exception
|
24
24
|
b = e.backtrace
|
25
25
|
@stderr.puts("#{b.shift}: #{e.message} (#{e.class})")
|
26
|
-
@stderr.puts(b.map{|s| "\tfrom #{s}"}.join("\n"))
|
26
|
+
@stderr.puts(b.map { |s| "\tfrom #{s}" }.join("\n"))
|
27
27
|
1
|
28
28
|
rescue SystemExit => e
|
29
29
|
e.status
|
data/lib/lastpassify/version.rb
CHANGED
data/script/autoformat
ADDED
@@ -0,0 +1,12 @@
|
|
1
|
+
#!/bin/sh
|
2
|
+
|
3
|
+
# script/autoformat: Run our code formatters
|
4
|
+
|
5
|
+
set -e
|
6
|
+
|
7
|
+
cd "$(dirname "$0")/.."
|
8
|
+
|
9
|
+
echo "==> Running Reek..."
|
10
|
+
bundle exec reek $(git diff --name-only --ignore-submodules=all --cached) --force-exclusion
|
11
|
+
echo "==> Running Standard..."
|
12
|
+
bundle exec standardrb
|
data/script/bootstrap
CHANGED
@@ -6,24 +6,18 @@ set -e
|
|
6
6
|
|
7
7
|
cd "$(dirname "$0")/.."
|
8
8
|
|
9
|
-
if [ "$(uname -s)" = "Darwin" ]; then
|
9
|
+
if [ -f "Brewfile" ] && [ "$(uname -s)" = "Darwin" ]; then
|
10
10
|
brew update
|
11
11
|
|
12
|
-
|
13
|
-
echo "==> Installing
|
14
|
-
brew
|
12
|
+
brew bundle check >/dev/null 2>&1 || {
|
13
|
+
echo "==> Installing Homebrew dependencies…"
|
14
|
+
brew bundle
|
15
15
|
}
|
16
16
|
fi
|
17
17
|
|
18
18
|
if [ -f "Gemfile" ]; then
|
19
19
|
echo "==> Installing gem dependencies…"
|
20
20
|
bundle check >/dev/null 2>&1 || {
|
21
|
-
bundle install --quiet
|
21
|
+
bundle install --quiet
|
22
22
|
}
|
23
23
|
fi
|
24
|
-
|
25
|
-
if [ -f ".overcommit.yml" ]; then
|
26
|
-
echo "==> Installing Overcommit hooks…"
|
27
|
-
bundle exec overcommit
|
28
|
-
bundle exec overcommit --sign
|
29
|
-
fi
|
data/script/lint
ADDED
@@ -0,0 +1,14 @@
|
|
1
|
+
#!/bin/sh
|
2
|
+
|
3
|
+
# script/lint: Run our code and security linters
|
4
|
+
|
5
|
+
set -e
|
6
|
+
|
7
|
+
cd "$(dirname "$0")/.."
|
8
|
+
|
9
|
+
echo "==> Checking Gems..."
|
10
|
+
bundle exec bundler-audit check --update
|
11
|
+
echo "==> Running Reek..."
|
12
|
+
bundle exec reek
|
13
|
+
echo "==> Running Standard..."
|
14
|
+
bundle exec standardrb --no-fix
|
data/script/setup
CHANGED
@@ -8,4 +8,11 @@ cd "$(dirname "$0")/.."
|
|
8
8
|
|
9
9
|
script/bootstrap
|
10
10
|
|
11
|
+
echo "==> Adding .git/safe…"
|
12
|
+
# https://thoughtbot.com/blog/git-safe
|
13
|
+
mkdir -p .git/safe
|
14
|
+
|
15
|
+
echo "==> Creating a pre-commit hook"
|
16
|
+
cp script/hooks/* .git/hooks
|
17
|
+
|
11
18
|
echo "==> LastPassify is now ready to go!"
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: lastpassify
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.4.
|
4
|
+
version: 0.4.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Eric Eklund (eeklund), Remy Abdullahi (abdu0299)
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2021-01-25 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -16,16 +16,16 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: '
|
19
|
+
version: '2.0'
|
20
20
|
type: :development
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
24
|
- - "~>"
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version: '
|
26
|
+
version: '2.0'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
|
-
name:
|
28
|
+
name: bundler-audit
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
31
|
- - ">="
|
@@ -39,7 +39,7 @@ dependencies:
|
|
39
39
|
- !ruby/object:Gem::Version
|
40
40
|
version: '0'
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
|
-
name:
|
42
|
+
name: rake
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
44
44
|
requirements:
|
45
45
|
- - ">="
|
@@ -53,7 +53,7 @@ dependencies:
|
|
53
53
|
- !ruby/object:Gem::Version
|
54
54
|
version: '0'
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
|
-
name:
|
56
|
+
name: standard
|
57
57
|
requirement: !ruby/object:Gem::Requirement
|
58
58
|
requirements:
|
59
59
|
- - ">="
|
@@ -67,7 +67,7 @@ dependencies:
|
|
67
67
|
- !ruby/object:Gem::Version
|
68
68
|
version: '0'
|
69
69
|
- !ruby/object:Gem::Dependency
|
70
|
-
name:
|
70
|
+
name: reek
|
71
71
|
requirement: !ruby/object:Gem::Requirement
|
72
72
|
requirements:
|
73
73
|
- - ">="
|
@@ -141,28 +141,28 @@ description: This gem populates a given ERB/YAML file with values from LastPass
|
|
141
141
|
email:
|
142
142
|
- eeklund@umn.edu
|
143
143
|
- abdu0299@umn.edu
|
144
|
-
executables:
|
145
|
-
- lastpassify
|
146
|
-
- reek
|
147
|
-
- rubocop
|
144
|
+
executables: []
|
148
145
|
extensions: []
|
149
146
|
extra_rdoc_files: []
|
150
147
|
files:
|
151
148
|
- ".gitignore"
|
152
|
-
- ".
|
153
|
-
- ".reek"
|
149
|
+
- ".reek.yml"
|
154
150
|
- ".ruby-version"
|
151
|
+
- ".standard.yml"
|
152
|
+
- Brewfile
|
155
153
|
- Gemfile
|
156
154
|
- Gemfile.lock
|
155
|
+
- LICENSE
|
157
156
|
- README.md
|
158
|
-
-
|
159
|
-
- bin/reek
|
160
|
-
- bin/rubocop
|
157
|
+
- changelog.md
|
161
158
|
- lastpassify.gemspec
|
162
159
|
- lib/lastpassify/lastpassify.rb
|
163
160
|
- lib/lastpassify/runner.rb
|
164
161
|
- lib/lastpassify/version.rb
|
162
|
+
- script/autoformat
|
165
163
|
- script/bootstrap
|
164
|
+
- script/hooks/pre-commit
|
165
|
+
- script/lint
|
166
166
|
- script/setup
|
167
167
|
- script/test
|
168
168
|
- script/update
|
@@ -170,7 +170,7 @@ homepage: https://github.com/umn-asr/lastpassify
|
|
170
170
|
licenses:
|
171
171
|
- MIT
|
172
172
|
metadata: {}
|
173
|
-
post_install_message:
|
173
|
+
post_install_message:
|
174
174
|
rdoc_options: []
|
175
175
|
require_paths:
|
176
176
|
- lib
|
@@ -178,16 +178,15 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
178
178
|
requirements:
|
179
179
|
- - ">="
|
180
180
|
- !ruby/object:Gem::Version
|
181
|
-
version: 2.
|
181
|
+
version: 2.3.0
|
182
182
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
183
183
|
requirements:
|
184
184
|
- - ">="
|
185
185
|
- !ruby/object:Gem::Version
|
186
186
|
version: '0'
|
187
187
|
requirements: []
|
188
|
-
|
189
|
-
|
190
|
-
signing_key:
|
188
|
+
rubygems_version: 3.1.2
|
189
|
+
signing_key:
|
191
190
|
specification_version: 4
|
192
191
|
summary: Populate ERB file with values from LastPass
|
193
192
|
test_files: []
|
data/.overcommit.yml
DELETED
@@ -1,17 +0,0 @@
|
|
1
|
-
PreCommit:
|
2
|
-
ALL:
|
3
|
-
exclude:
|
4
|
-
- "lib/lastpassify/runner.rb"
|
5
|
-
RuboCop:
|
6
|
-
enabled: true
|
7
|
-
on_warn: fail # Treat all warnings as failures
|
8
|
-
required_executable: "./bin/rubocop"
|
9
|
-
Reek:
|
10
|
-
enabled: true
|
11
|
-
on_fail: fail
|
12
|
-
required_executable: "./bin/reek"
|
13
|
-
PrePush:
|
14
|
-
RSpec:
|
15
|
-
enabled: true
|
16
|
-
on_warn: fail # Treat all warnings as failures
|
17
|
-
required_executable: './script/test'
|
data/.reek
DELETED
data/bin/lastpassify
DELETED
data/bin/reek
DELETED
@@ -1,17 +0,0 @@
|
|
1
|
-
#!/usr/bin/env ruby
|
2
|
-
# frozen_string_literal: true
|
3
|
-
#
|
4
|
-
# This file was generated by Bundler.
|
5
|
-
#
|
6
|
-
# The application 'reek' is installed as part of a gem, and
|
7
|
-
# this file is here to facilitate running it.
|
8
|
-
#
|
9
|
-
|
10
|
-
require "pathname"
|
11
|
-
ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../Gemfile",
|
12
|
-
Pathname.new(__FILE__).realpath)
|
13
|
-
|
14
|
-
require "rubygems"
|
15
|
-
require "bundler/setup"
|
16
|
-
|
17
|
-
load Gem.bin_path("reek", "reek")
|
data/bin/rubocop
DELETED
@@ -1,17 +0,0 @@
|
|
1
|
-
#!/usr/bin/env ruby
|
2
|
-
# frozen_string_literal: true
|
3
|
-
#
|
4
|
-
# This file was generated by Bundler.
|
5
|
-
#
|
6
|
-
# The application 'rubocop' is installed as part of a gem, and
|
7
|
-
# this file is here to facilitate running it.
|
8
|
-
#
|
9
|
-
|
10
|
-
require "pathname"
|
11
|
-
ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../Gemfile",
|
12
|
-
Pathname.new(__FILE__).realpath)
|
13
|
-
|
14
|
-
require "rubygems"
|
15
|
-
require "bundler/setup"
|
16
|
-
|
17
|
-
load Gem.bin_path("rubocop", "rubocop")
|