organize 1.0.1 → 1.1.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,51 +1,43 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- organize (0.1.0)
4
+ organize (1.0.1)
5
5
  optitron (~> 0.2)
6
6
 
7
7
  GEM
8
8
  remote: http://rubygems.org/
9
9
  specs:
10
10
  callsite (0.0.4)
11
- derickbailey-notamock (0.0.1)
12
- rspec (>= 1.2.9)
13
11
  diff-lcs (1.1.2)
14
- fakefs (0.2.1)
15
- infinity_test (0.2.0)
16
- watchr (>= 0.7)
17
- optitron (0.2.0)
18
- callsite (~> 0.0.4)
12
+ fakefs (0.3.1)
13
+ method-args (0.1.1)
19
14
  ruby2ruby (~> 1.2.4)
20
15
  ruby_parser (~> 2.0)
21
16
  sexp_processor (~> 3.0.4)
22
- rspec (2.0.0.beta.22)
23
- rspec-core (= 2.0.0.beta.22)
24
- rspec-expectations (= 2.0.0.beta.22)
25
- rspec-mocks (= 2.0.0.beta.22)
26
- rspec-core (2.0.0.beta.22)
27
- rspec-expectations (2.0.0.beta.22)
28
- diff-lcs (>= 1.1.2)
29
- rspec-mocks (2.0.0.beta.22)
30
- rspec-core (= 2.0.0.beta.22)
31
- rspec-expectations (= 2.0.0.beta.22)
17
+ optitron (0.3.1)
18
+ callsite (~> 0.0.4)
19
+ method-args (~> 0.1.0)
20
+ rspec (2.4.0)
21
+ rspec-core (~> 2.4.0)
22
+ rspec-expectations (~> 2.4.0)
23
+ rspec-mocks (~> 2.4.0)
24
+ rspec-core (2.4.0)
25
+ rspec-expectations (2.4.0)
26
+ diff-lcs (~> 1.1.2)
27
+ rspec-mocks (2.4.0)
32
28
  ruby2ruby (1.2.5)
33
29
  ruby_parser (~> 2.0)
34
30
  sexp_processor (~> 3.0)
35
31
  ruby_parser (2.0.5)
36
32
  sexp_processor (~> 3.0)
37
33
  sexp_processor (3.0.5)
38
- watchr (0.7)
39
34
 
40
35
  PLATFORMS
41
36
  ruby
42
37
 
43
38
  DEPENDENCIES
44
39
  bundler (~> 1.0)
45
- derickbailey-notamock (~> 0.0.1)
46
40
  fakefs (~> 0.2)
47
- infinity_test (~> 0.2)
48
41
  optitron (~> 0.2)
49
42
  organize!
50
- rspec (= 2.0.0.beta.22)
51
- watchr (~> 0.6)
43
+ rspec (~> 2.4)
data/README.md CHANGED
@@ -32,15 +32,11 @@ projects like Areas of Responsibility. These are *large* goals in your life that
32
32
  won't be completed for a couple months or will never be completed. Don't make
33
33
  too many of them. I usually have around 13 or so.
34
34
 
35
- Inside of each project folder, there are two folders created for you
35
+ Inside of each project folder, there is a single Shared folder created for you
36
36
  automatically. The Shared folder links to a folder in your
37
37
  [Dropbox](http://www.dropbox.com/) of the same name as the project. Anything
38
38
  that you'd like to share across multiple computers should be placed in here.
39
39
 
40
- The other folder is the Archive folder. Treat this like the Archive folder of
41
- Gmail. Don't delete things that you may possibly need later. Put them in the
42
- Archive for storage.
43
-
44
40
  Organize also creates a couple other folders. The Archive folder located in the
45
41
  root of the Projects folder are for old projects that you've completed but would
46
42
  like to still have the file around, just in case something bad happens. The
@@ -13,10 +13,6 @@ module Organize
13
13
  File.join(PREFIX, name)
14
14
  end
15
15
 
16
- def archive_path
17
- File.join(path, 'Archive')
18
- end
19
-
20
16
  def shared_path
21
17
  File.join(SHARED_PREFIX, name)
22
18
  end
@@ -32,7 +28,6 @@ module Organize
32
28
  def create
33
29
  FileUtils.mkdir_p(path)
34
30
  FileUtils.mkdir_p(shared_path)
35
- FileUtils.mkdir_p(archive_path)
36
31
  FileUtils.mkdir_p(project_archive_path)
37
32
  FileUtils.ln_s(shared_path, shared_link_path) unless File.exists?(shared_link_path)
38
33
  end
@@ -1,3 +1,3 @@
1
1
  module Organize
2
- VERSION = '1.0.1'
2
+ VERSION = '1.1.0'
3
3
  end
@@ -18,13 +18,10 @@ Gem::Specification.new do |s|
18
18
  s.add_dependency 'optitron', '~> 0.2'
19
19
 
20
20
  s.add_development_dependency 'bundler', '~> 1.0'
21
- s.add_development_dependency 'rspec', '2.0.0.beta.22'
22
- s.add_development_dependency 'watchr', '~> 0.6'
23
- s.add_development_dependency 'derickbailey-notamock', '~> 0.0.1'
24
- s.add_development_dependency 'fakefs', '~> 0.2'
25
- s.add_development_dependency 'infinity_test', '~> 0.2'
21
+ s.add_development_dependency 'rspec', '~> 2.4'
22
+ s.add_development_dependency 'fakefs', '~> 0.2'
26
23
 
27
24
  s.files = `git ls-files`.split("\n")
28
- s.executables = `git ls-files`.split("\n").map {|f| f[%r{^bin/(.*)}, 1]}.compact
25
+ s.executables = `git ls-files`.split("\n").map { |f| f[%r{^bin/(.*)}, 1] }.compact
29
26
  s.require_path = 'lib'
30
27
  end
@@ -1,97 +1,54 @@
1
1
  require 'spec_helper'
2
2
 
3
3
  describe Organize::Project do
4
- let(:project) { Organize::Project.new 'Foo' }
5
- subject { project }
6
-
7
- it 'should have a name' do
8
- subject.name.should == 'Foo'
4
+ before do
5
+ @project = Organize::Project.new 'Foo'
9
6
  end
10
7
 
11
- describe '#path' do
12
- before do
13
- project.track_methods :name
14
- subject
15
- end
16
-
17
- subject { project.path }
18
-
19
- it 'should combine the prefix and name' do
20
- project.should have_received(:name)
21
- should == File.expand_path('~/Projects/Foo')
22
- end
8
+ it "should have a #name" do
9
+ @project.name.should == 'Foo'
23
10
  end
24
11
 
25
- describe '#archive_path' do
26
- before do
27
- project.track_methods :path
28
- subject
29
- end
30
-
31
- subject { project.archive_path }
32
-
33
- it 'should tack on Archive to the end of the path' do
34
- project.should have_received(:path)
35
- should == File.expand_path('~/Projects/Foo/Archive')
12
+ describe "#path" do
13
+ it "should concatenate the prefix and #name" do
14
+ @project.path.should == File.expand_path('~/Projects/Foo')
36
15
  end
37
16
  end
38
17
 
39
- describe '#shared_path' do
40
- before do
41
- project.track_methods :name
42
- subject
43
- end
44
-
45
- subject { project.shared_path }
46
-
47
- it 'should tack on the name to the end of the shared path' do
48
- project.should have_received(:name)
49
- should == File.expand_path('~/Dropbox/Foo')
18
+ describe "#shared_path" do
19
+ it "should concatenate the shared prefix #name" do
20
+ @project.shared_path.should == File.expand_path('~/Dropbox/Foo')
50
21
  end
51
22
  end
52
23
 
53
- describe '#shared_link_path' do
54
- before do
55
- project.track_methods :path
56
- subject
57
- end
58
-
59
- subject { project.shared_link_path }
60
-
61
- it 'should tack on Shared to the end of the path' do
62
- project.should have_received(:path)
63
- should == File.expand_path('~/Projects/Foo/Shared')
24
+ describe "#shared_link_path" do
25
+ it "should concatenate the #path and Shared" do
26
+ @project.shared_link_path.should == File.expand_path('~/Projects/Foo/Shared')
64
27
  end
65
28
  end
66
29
 
67
- describe '#project_archive_path' do
68
- subject { project.project_archive_path }
69
-
70
- it 'should tack on Archive to the end of the prefix' do
71
- should == File.expand_path('~/Projects/Archive')
30
+ describe "#project_archive_path" do
31
+ it "should tack on Archive to the end of the prefix" do
32
+ @project.project_archive_path.should == File.expand_path('~/Projects/Archive')
72
33
  end
73
34
  end
74
35
 
75
- describe '#create' do
36
+ describe "#create" do
76
37
  before do
77
- FileUtils.rm_rf(File.expand_path('~'))
78
- project.create
79
- end
80
-
81
- it 'should create the project directory' do
82
- File.directory?(project.path).should be_true
38
+ FileUtils.rm_rf File.expand_path('~')
39
+ @project.create
83
40
  end
84
41
 
85
- it 'should create the shared project directory' do
86
- File.directory?(project.shared_path).should be_true
42
+ it "should create the project directory" do
43
+ File.directory?(@project.path).should be_true
87
44
  end
88
45
 
89
- it 'should creat the archive directory' do
90
- File.directory?(project.archive_path).should be_true
46
+ it "should create the shared project directory" do
47
+ File.directory?(@project.shared_path).should be_true
91
48
  end
92
49
 
93
- it 'should create the project archive directory' do
94
- File.directory?(project.project_archive_path).should be_true
50
+ it "should create the project archive directory" do
51
+ File.directory?(@project.project_archive_path).should be_true
95
52
  end
96
53
  end
97
54
  end
@@ -1,10 +1,8 @@
1
1
  require 'spec_helper'
2
2
 
3
3
  describe Organize::Runner do
4
- let(:runner) { Organize::Runner }
5
- subject { runner }
6
-
7
4
  before do
5
+ @runner = Organize::Runner
8
6
  FileUtils.rm_rf '~'
9
7
 
10
8
  %w{Desktop Documents Movies Music Pictures Public Sites}.each do |directory|
@@ -13,24 +11,26 @@ describe Organize::Runner do
13
11
  end
14
12
  end
15
13
 
16
- describe '#install' do
17
- before { runner.dispatch(%w{install}) }
14
+ describe "#install" do
15
+ before do
16
+ @runner.dispatch(%w{install})
17
+ end
18
18
 
19
- it 'should create the prefixes' do
19
+ it "should create the prefixes" do
20
20
  %w{Projects Dropbox}.each do |directory|
21
21
  directory = File.expand_path("~/#{directory}")
22
22
  File.directory?(directory).should be_true
23
23
  end
24
24
  end
25
25
 
26
- it 'should create the Inbox and Other projects' do
26
+ it "should create the Inbox and Other projects" do
27
27
  %w{Inbox Other}.each do |directory|
28
28
  directory = File.expand_path("~/Projects/#{directory}")
29
29
  File.directory?(directory).should be_true
30
30
  end
31
31
  end
32
32
 
33
- it 'should symlink the Other directories' do
33
+ it "should symlink the Other directories" do
34
34
  %w{Documents Movies Music Pictures Public Sites}.each do |directory|
35
35
  directory = File.expand_path("~/Projects/Other/#{directory}")
36
36
  File.symlink?(directory).should be_true
@@ -38,13 +38,13 @@ describe Organize::Runner do
38
38
  end
39
39
  end
40
40
 
41
- describe '#create' do
41
+ describe "#create" do
42
42
  before do
43
- runner.dispatch(%w{install})
44
- runner.dispatch(%w{create Foo})
43
+ @runner.dispatch(%w{install})
44
+ @runner.dispatch(%w{create Foo})
45
45
  end
46
46
 
47
- it 'should create the new project' do
47
+ it "should create the new project" do
48
48
  File.directory?('~/Projects/Foo').should be_true
49
49
  end
50
50
  end
@@ -1,13 +1,12 @@
1
1
  require 'bundler/setup'
2
2
 
3
3
  require 'rspec'
4
- require 'not_a_mock'
5
4
  require 'fakefs/spec_helpers'
6
5
 
7
6
  require 'organize'
8
7
  Dir[File.dirname(__FILE__) + '/support/**/*.rb'].each { |f| require f }
9
8
 
10
9
  RSpec.configure do |config|
11
- config.mock_with NotAMock::RspecMockFrameworkAdapter
10
+ config.mock_with :rspec
12
11
  config.include FakeFS::SpecHelpers
13
12
  end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: organize
3
3
  version: !ruby/object:Gem::Version
4
- hash: 21
5
- prerelease: false
4
+ hash: 19
5
+ prerelease:
6
6
  segments:
7
7
  - 1
8
- - 0
9
8
  - 1
10
- version: 1.0.1
9
+ - 0
10
+ version: 1.1.0
11
11
  platform: ruby
12
12
  authors:
13
13
  - Alexander Kern
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2010-10-05 00:00:00 -07:00
18
+ date: 2011-01-11 00:00:00 -08:00
19
19
  default_executable:
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency
@@ -54,68 +54,19 @@ dependencies:
54
54
  requirement: &id003 !ruby/object:Gem::Requirement
55
55
  none: false
56
56
  requirements:
57
- - - "="
57
+ - - ~>
58
58
  - !ruby/object:Gem::Version
59
- hash: 62196431
59
+ hash: 11
60
60
  segments:
61
61
  - 2
62
- - 0
63
- - 0
64
- - beta
65
- - 22
66
- version: 2.0.0.beta.22
62
+ - 4
63
+ version: "2.4"
67
64
  type: :development
68
65
  version_requirements: *id003
69
- - !ruby/object:Gem::Dependency
70
- name: watchr
71
- prerelease: false
72
- requirement: &id004 !ruby/object:Gem::Requirement
73
- none: false
74
- requirements:
75
- - - ~>
76
- - !ruby/object:Gem::Version
77
- hash: 7
78
- segments:
79
- - 0
80
- - 6
81
- version: "0.6"
82
- type: :development
83
- version_requirements: *id004
84
- - !ruby/object:Gem::Dependency
85
- name: derickbailey-notamock
86
- prerelease: false
87
- requirement: &id005 !ruby/object:Gem::Requirement
88
- none: false
89
- requirements:
90
- - - ~>
91
- - !ruby/object:Gem::Version
92
- hash: 29
93
- segments:
94
- - 0
95
- - 0
96
- - 1
97
- version: 0.0.1
98
- type: :development
99
- version_requirements: *id005
100
66
  - !ruby/object:Gem::Dependency
101
67
  name: fakefs
102
68
  prerelease: false
103
- requirement: &id006 !ruby/object:Gem::Requirement
104
- none: false
105
- requirements:
106
- - - ~>
107
- - !ruby/object:Gem::Version
108
- hash: 15
109
- segments:
110
- - 0
111
- - 2
112
- version: "0.2"
113
- type: :development
114
- version_requirements: *id006
115
- - !ruby/object:Gem::Dependency
116
- name: infinity_test
117
- prerelease: false
118
- requirement: &id007 !ruby/object:Gem::Requirement
69
+ requirement: &id004 !ruby/object:Gem::Requirement
119
70
  none: false
120
71
  requirements:
121
72
  - - ~>
@@ -126,7 +77,7 @@ dependencies:
126
77
  - 2
127
78
  version: "0.2"
128
79
  type: :development
129
- version_requirements: *id007
80
+ version_requirements: *id004
130
81
  description: Creates directories and links to manage your Mac consistently.
131
82
  email:
132
83
  - alex@kernul.com
@@ -153,8 +104,7 @@ files:
153
104
  - spec/organize/project_spec.rb
154
105
  - spec/organize/runner_spec.rb
155
106
  - spec/spec_helper.rb
156
- - spec/support/helpers/capture.rb
157
- - spec/support/matchers/matchers.rb
107
+ - spec/support/helpers.rb
158
108
  has_rdoc: true
159
109
  homepage: http://github.com/CapnKernul/organize
160
110
  licenses: []
@@ -187,7 +137,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
187
137
  requirements: []
188
138
 
189
139
  rubyforge_project: organize
190
- rubygems_version: 1.3.7
140
+ rubygems_version: 1.4.1
191
141
  signing_key:
192
142
  specification_version: 3
193
143
  summary: Organize your Mac filesystem.
@@ -1,15 +0,0 @@
1
- require 'stringio'
2
-
3
- def capture(*streams)
4
- streams.map! { |stream| stream.to_s }
5
-
6
- begin
7
- result = StringIO.new
8
- streams.each { |stream| eval "$#{stream} = result" }
9
- yield
10
- ensure
11
- streams.each { |stream| eval("$#{stream} = #{stream.upcase}") }
12
- end
13
-
14
- result.string
15
- end