safe 0.2 → 0.3
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.
- data/README +10 -9
- data/Rakefile +60 -0
- data/Release-Notes.txt +17 -0
- data/bin/{safe.rb → safe} +2 -2
- data/index.html +17 -0
- metadata +13 -10
data/README
CHANGED
@@ -57,19 +57,20 @@ Windows:
|
|
57
57
|
== Version History ==
|
58
58
|
0.1 -- May 12, 2007
|
59
59
|
0.2 -- August 19, 2007
|
60
|
+
0.3 -- September 7, 2007
|
60
61
|
|
61
62
|
See Release-Notes.txt for more information
|
62
63
|
|
63
64
|
== Usage ==
|
64
65
|
Run safe by typing:
|
65
66
|
|
66
|
-
safe
|
67
|
+
safe
|
67
68
|
|
68
69
|
The first time you run safe, you will be prompted for a password, and a new
|
69
70
|
password file (.safe.xml) will be created in the directory specified by
|
70
71
|
SAFE_DIR, like this:
|
71
72
|
|
72
|
-
$ safe
|
73
|
+
$ safe
|
73
74
|
Password: ****
|
74
75
|
Creating new file . . .
|
75
76
|
|
@@ -91,11 +92,11 @@ existing directory.
|
|
91
92
|
|
92
93
|
If you type:
|
93
94
|
|
94
|
-
safe
|
95
|
+
safe -h
|
95
96
|
|
96
97
|
the available options display. They are:
|
97
98
|
|
98
|
-
Usage: safe
|
99
|
+
Usage: safe [options]
|
99
100
|
|
100
101
|
Options:
|
101
102
|
-a, --add NAME Add an entry
|
@@ -108,7 +109,7 @@ Options:
|
|
108
109
|
|
109
110
|
For example, to add an entry to your password file for Rubyforge.org, you type:
|
110
111
|
|
111
|
-
safe
|
112
|
+
safe -a Rubyforge.org
|
112
113
|
|
113
114
|
You will be prompted for your master password, and then your Rubyforge.org
|
114
115
|
user ID and password, like this:
|
@@ -119,11 +120,11 @@ user ID and password, like this:
|
|
119
120
|
|
120
121
|
NOTE: If NAME contains spaces, you must surround it in quotes, like this:
|
121
122
|
|
122
|
-
safe
|
123
|
+
safe -a "A Cool Site"
|
123
124
|
|
124
125
|
To list your Rubyforge.org password, you type:
|
125
126
|
|
126
|
-
safe
|
127
|
+
safe -l Rubyforge.org
|
127
128
|
|
128
129
|
You will be prompted for your master password, and then your Rubyforge.org
|
129
130
|
user ID and password will display, like this:
|
@@ -133,13 +134,13 @@ user ID and password will display, like this:
|
|
133
134
|
NOTE: The NAME you pass to -l is not case sensitive, and will find all entries
|
134
135
|
beginning with NAME. For example, typing:
|
135
136
|
|
136
|
-
safe
|
137
|
+
safe -l r
|
137
138
|
|
138
139
|
will list all entries beginning with "r" or "R."
|
139
140
|
|
140
141
|
To delete your Rubyforge.org password, you type:
|
141
142
|
|
142
|
-
safe
|
143
|
+
safe -d Rubyforge.org
|
143
144
|
|
144
145
|
You will be prompted for your master password, and then your Rubyforge.org
|
145
146
|
password is irretrievably deleted. You will not be asked to confirm the
|
data/Rakefile
ADDED
@@ -0,0 +1,60 @@
|
|
1
|
+
require 'rake/testtask'
|
2
|
+
require 'rake/gempackagetask'
|
3
|
+
|
4
|
+
gem_spec = Gem::Specification.new do |spec|
|
5
|
+
# Program information
|
6
|
+
spec.name = 'safe'
|
7
|
+
spec.summary = 'A command-line password storage program'
|
8
|
+
spec.description = %{safe safely stores all your user IDs and passwords,
|
9
|
+
encrypted by a password of your choosing.}
|
10
|
+
spec.version = '0.3'
|
11
|
+
|
12
|
+
# Author information
|
13
|
+
spec.author = 'Rob Warner'
|
14
|
+
spec.email = 'rwarner@grailbox.com'
|
15
|
+
spec.homepage = 'http://safe.rubyforge.org/'
|
16
|
+
spec.rubyforge_project = 'safe'
|
17
|
+
|
18
|
+
# Files
|
19
|
+
spec.test_files = FileList['test/**/*']
|
20
|
+
spec.bindir = 'bin'
|
21
|
+
spec.executables = ['safe']
|
22
|
+
spec.default_executable = 'safe'
|
23
|
+
spec.files = FileList['README', 'lib/**/*.rb', 'index.html', 'Rakefile',
|
24
|
+
'README', 'Release-Notes.txt']
|
25
|
+
|
26
|
+
# Dependencies
|
27
|
+
spec.add_dependency('crypt', '>= 1.1.4')
|
28
|
+
spec.add_dependency('highline', '>= 1.4.0')
|
29
|
+
end
|
30
|
+
|
31
|
+
Rake::TestTask.new('test') do |t|
|
32
|
+
t.pattern = 'test/**/tc_*.rb'
|
33
|
+
t.warning = true
|
34
|
+
end
|
35
|
+
|
36
|
+
Rake::GemPackageTask.new(gem_spec) do |pkg|
|
37
|
+
end
|
38
|
+
|
39
|
+
task :web do
|
40
|
+
# Read in the HTML template
|
41
|
+
f = File.open "index.html"
|
42
|
+
html = f.read
|
43
|
+
f.close
|
44
|
+
|
45
|
+
# Read in the readme
|
46
|
+
f = File.open "README"
|
47
|
+
readme = f.read
|
48
|
+
f.close
|
49
|
+
|
50
|
+
# Transform the headings
|
51
|
+
readme.gsub!(/===(.*?)===/, '<h1>\1</h1>')
|
52
|
+
readme.gsub!(/==(.*?)==/, '<h2>\1</h2>')
|
53
|
+
readme.gsub!(/\n/, '<br />')
|
54
|
+
html.sub!("<!-- Insert your content here -->", readme)
|
55
|
+
|
56
|
+
# Output the HTML
|
57
|
+
f = File.open "pkg/index.html", "w"
|
58
|
+
f.puts html
|
59
|
+
f.close
|
60
|
+
end
|
data/Release-Notes.txt
ADDED
@@ -0,0 +1,17 @@
|
|
1
|
+
Safe Release Notes
|
2
|
+
------------------
|
3
|
+
|
4
|
+
0.3 (September 7, 2007)
|
5
|
+
---------------------
|
6
|
+
[NEW] Added support files to gem
|
7
|
+
[NEW] Specified versions for highline and crypt
|
8
|
+
[NEW] Changed executable from 'safe.rb' to 'safe'
|
9
|
+
|
10
|
+
0.2 (August 19, 2007)
|
11
|
+
---------------------
|
12
|
+
[NEW] Change password of safe file (-p, --password flag)
|
13
|
+
[NEW] Packaged as gem
|
14
|
+
|
15
|
+
0.1 (May 12, 2007)
|
16
|
+
------------------
|
17
|
+
Initial Release
|
data/bin/{safe.rb → safe}
RENAMED
@@ -41,14 +41,14 @@ require File.join(File.dirname(__FILE__), '..', 'lib', 'safeutils')
|
|
41
41
|
# TODO support list <NAME> without -l flag
|
42
42
|
|
43
43
|
class Safe
|
44
|
-
SAFE_VERSION = '0.
|
44
|
+
SAFE_VERSION = '0.3'
|
45
45
|
|
46
46
|
# Gets the command line
|
47
47
|
def self.get_command_line
|
48
48
|
options = {}
|
49
49
|
options[:action] = 'list'
|
50
50
|
opts = OptionParser.new
|
51
|
-
opts.banner = 'Usage: safe
|
51
|
+
opts.banner = 'Usage: safe [options]'
|
52
52
|
opts.separator ''
|
53
53
|
opts.separator 'Options:'
|
54
54
|
opts.on('-a', '--add NAME', 'Add an entry') do |val|
|
data/index.html
ADDED
@@ -0,0 +1,17 @@
|
|
1
|
+
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
2
|
+
<html lang="en">
|
3
|
+
<head>
|
4
|
+
<title>Safe</title>
|
5
|
+
</head>
|
6
|
+
<body>
|
7
|
+
<a href="http://grailbox.com">Grailbox Home</a>
|
8
|
+
<br />
|
9
|
+
<a href="http://rubyforge.org/projects/safe">Downloads</a>
|
10
|
+
<br />
|
11
|
+
<img src="safe.png" alt="Safe" />
|
12
|
+
<!-- Insert your content here -->
|
13
|
+
<a href="http://grailbox.com">Grailbox Home</a>
|
14
|
+
<br />
|
15
|
+
<a href="http://rubyforge.org/projects/safe">Downloads</a>
|
16
|
+
</body>
|
17
|
+
</html>
|
metadata
CHANGED
@@ -3,17 +3,17 @@ rubygems_version: 0.9.4
|
|
3
3
|
specification_version: 1
|
4
4
|
name: safe
|
5
5
|
version: !ruby/object:Gem::Version
|
6
|
-
version: "0.
|
7
|
-
date: 2007-
|
6
|
+
version: "0.3"
|
7
|
+
date: 2007-09-07 00:00:00 -04:00
|
8
8
|
summary: A command-line password storage program
|
9
9
|
require_paths:
|
10
10
|
- lib
|
11
11
|
email: rwarner@grailbox.com
|
12
|
-
homepage: http://
|
13
|
-
rubyforge_project:
|
12
|
+
homepage: http://safe.rubyforge.org/
|
13
|
+
rubyforge_project: safe
|
14
14
|
description: safe safely stores all your user IDs and passwords, encrypted by a password of your choosing.
|
15
15
|
autorequire:
|
16
|
-
default_executable:
|
16
|
+
default_executable: safe
|
17
17
|
bindir: bin
|
18
18
|
has_rdoc: false
|
19
19
|
required_ruby_version: !ruby/object:Gem::Version::Requirement
|
@@ -33,6 +33,9 @@ files:
|
|
33
33
|
- lib/safeentry.rb
|
34
34
|
- lib/safefile.rb
|
35
35
|
- lib/safeutils.rb
|
36
|
+
- index.html
|
37
|
+
- Rakefile
|
38
|
+
- Release-Notes.txt
|
36
39
|
test_files:
|
37
40
|
- test/tc_safefile.rb
|
38
41
|
- test/tc_safeentry.rb
|
@@ -42,7 +45,7 @@ rdoc_options: []
|
|
42
45
|
extra_rdoc_files: []
|
43
46
|
|
44
47
|
executables:
|
45
|
-
- safe
|
48
|
+
- safe
|
46
49
|
extensions: []
|
47
50
|
|
48
51
|
requirements: []
|
@@ -53,16 +56,16 @@ dependencies:
|
|
53
56
|
version_requirement:
|
54
57
|
version_requirements: !ruby/object:Gem::Version::Requirement
|
55
58
|
requirements:
|
56
|
-
- - "
|
59
|
+
- - ">="
|
57
60
|
- !ruby/object:Gem::Version
|
58
|
-
version:
|
61
|
+
version: 1.1.4
|
59
62
|
version:
|
60
63
|
- !ruby/object:Gem::Dependency
|
61
64
|
name: highline
|
62
65
|
version_requirement:
|
63
66
|
version_requirements: !ruby/object:Gem::Version::Requirement
|
64
67
|
requirements:
|
65
|
-
- - "
|
68
|
+
- - ">="
|
66
69
|
- !ruby/object:Gem::Version
|
67
|
-
version:
|
70
|
+
version: 1.4.0
|
68
71
|
version:
|