playpen 1.0.0 → 1.1.0

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.
File without changes
@@ -1,3 +1,12 @@
1
+ === 1.1.0 / 2011-05-12
2
+
3
+ * 1 enhancement
4
+
5
+ * Added files to be required from the command line. For example, to raise
6
+ an exception if bundler tries to access the network:
7
+
8
+ $ ruby -rubygems -rplaypen/no_network -S bundle
9
+
1
10
  === 1.0.0 / 2010-10-07
2
11
 
3
12
  * 1 major enhancement
@@ -6,4 +6,9 @@ Rakefile
6
6
  ext/playpen/extconf.rb
7
7
  ext/playpen/playpen.c
8
8
  lib/playpen.rb
9
+ lib/playpen/computation_only.rb
10
+ lib/playpen/no_internet.rb
11
+ lib/playpen/no_network.rb
12
+ lib/playpen/no_write.rb
13
+ lib/playpen/temp_only_write.rb
9
14
  test/test_playpen.rb
@@ -14,8 +14,15 @@ same API that the Sandbox class in MacRuby provides.
14
14
 
15
15
  == SYNOPSIS:
16
16
 
17
+ From code:
18
+
19
+ require 'playpen'
17
20
  Playpen.no_internet.apply!
18
21
 
22
+ From the command line (with bundler):
23
+
24
+ $ ruby -rubygems -rplaypen/computation_only -S bundle
25
+
19
26
  == REQUIREMENTS:
20
27
 
21
28
  * OS X 10.5 or greater
@@ -28,7 +35,10 @@ same API that the Sandbox class in MacRuby provides.
28
35
 
29
36
  (The MIT License)
30
37
 
31
- Copyright (c) 2010 Aaron Patterson, Evan Phoenix
38
+ Copyright (c) 2010-2011
39
+
40
+ * Aaron Patterson
41
+ * Evan Phoenix
32
42
 
33
43
  Permission is hereby granted, free of charge, to any person obtaining
34
44
  a copy of this software and associated documentation files (the
data/Rakefile CHANGED
@@ -5,7 +5,7 @@ require 'hoe'
5
5
  gem 'rake-compiler', '>= 0.4.1'
6
6
  require "rake/extensiontask"
7
7
 
8
- Hoe.spec 'playpen' do
8
+ Hoe.spec 'playpen' do |s|
9
9
  developer('Aaron Patterson', 'aaron@tenderlovemaking.com')
10
10
  developer('Evan Phoenix', 'evan@fallingsnow.net')
11
11
  self.readme_file = 'README.rdoc'
@@ -13,8 +13,8 @@ Hoe.spec 'playpen' do
13
13
  self.extra_rdoc_files = FileList['*.rdoc']
14
14
  self.spec_extras = { :extensions => ["ext/playpen/extconf.rb"] }
15
15
 
16
- Rake::ExtensionTask.new "playpen", spec do |ext|
17
- ext.lib_dir = File.join(*['lib', 'playpen', ENV['FAT_DIR']].compact)
16
+ Rake::ExtensionTask.new s.name, spec do |ext|
17
+ ext.lib_dir = File.join(*['lib', s.name, ENV['FAT_DIR']].compact)
18
18
  end
19
19
  end
20
20
 
@@ -1,7 +1,7 @@
1
1
  require 'playpen/playpen'
2
2
 
3
3
  class Playpen
4
- VERSION = '1.0.0'
4
+ VERSION = '1.1.0'
5
5
 
6
6
  def initialize
7
7
  @commands = []
@@ -9,7 +9,7 @@ class Playpen
9
9
 
10
10
  def apply!
11
11
  @commands.each do |command|
12
- self.class.sandbox_init(command, Playpen::SANDBOX_NAMED)
12
+ self.class.sandbox_init command, Playpen::SANDBOX_NAMED
13
13
  end
14
14
  end
15
15
 
@@ -0,0 +1,3 @@
1
+ require 'playpen'
2
+
3
+ Playpen.computation_only.apply!
@@ -0,0 +1,3 @@
1
+ require 'playpen'
2
+
3
+ Playpen.no_internet.apply!
@@ -0,0 +1,3 @@
1
+ require 'playpen'
2
+
3
+ Playpen.no_network.apply!
@@ -0,0 +1,3 @@
1
+ require 'playpen'
2
+
3
+ Playpen.no_write.apply!
@@ -0,0 +1,3 @@
1
+ require 'playpen'
2
+
3
+ Playpen.temp_only_write.apply!
metadata CHANGED
@@ -1,71 +1,43 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: playpen
3
- version: !ruby/object:Gem::Version
4
- hash: 23
5
- prerelease: false
6
- segments:
7
- - 1
8
- - 0
9
- - 0
10
- version: 1.0.0
3
+ version: !ruby/object:Gem::Version
4
+ version: 1.1.0
5
+ prerelease:
11
6
  platform: ruby
12
- authors:
7
+ authors:
13
8
  - Aaron Patterson
14
9
  - Evan Phoenix
15
10
  autorequire:
16
11
  bindir: bin
17
12
  cert_chain: []
18
-
19
- date: 2010-10-07 00:00:00 -06:00
20
- default_executable:
21
- dependencies:
22
- - !ruby/object:Gem::Dependency
23
- name: rubyforge
24
- prerelease: false
25
- requirement: &id001 !ruby/object:Gem::Requirement
26
- none: false
27
- requirements:
28
- - - ">="
29
- - !ruby/object:Gem::Version
30
- hash: 7
31
- segments:
32
- - 2
33
- - 0
34
- - 4
35
- version: 2.0.4
36
- type: :development
37
- version_requirements: *id001
38
- - !ruby/object:Gem::Dependency
13
+ date: 2011-05-13 00:00:00.000000000 Z
14
+ dependencies:
15
+ - !ruby/object:Gem::Dependency
39
16
  name: hoe
40
- prerelease: false
41
- requirement: &id002 !ruby/object:Gem::Requirement
17
+ requirement: &2153366520 !ruby/object:Gem::Requirement
42
18
  none: false
43
- requirements:
44
- - - ">="
45
- - !ruby/object:Gem::Version
46
- hash: 19
47
- segments:
48
- - 2
49
- - 6
50
- - 2
51
- version: 2.6.2
19
+ requirements:
20
+ - - ! '>='
21
+ - !ruby/object:Gem::Version
22
+ version: 2.9.1
52
23
  type: :development
53
- version_requirements: *id002
54
- description: |-
55
- Playpen wraps OS X sandbox api with a loving embrace. Playpen provides the
56
- same API that the Sandbox class in MacRuby provides.
57
- email:
24
+ prerelease: false
25
+ version_requirements: *2153366520
26
+ description: ! 'Playpen wraps OS X sandbox api with a loving embrace. Playpen provides
27
+ the
28
+
29
+ same API that the Sandbox class in MacRuby provides.'
30
+ email:
58
31
  - aaron@tenderlovemaking.com
59
32
  - evan@fallingsnow.net
60
33
  executables: []
61
-
62
- extensions:
34
+ extensions:
63
35
  - ext/playpen/extconf.rb
64
- extra_rdoc_files:
36
+ extra_rdoc_files:
65
37
  - Manifest.txt
66
38
  - CHANGELOG.rdoc
67
39
  - README.rdoc
68
- files:
40
+ files:
69
41
  - .autotest
70
42
  - CHANGELOG.rdoc
71
43
  - Manifest.txt
@@ -74,41 +46,38 @@ files:
74
46
  - ext/playpen/extconf.rb
75
47
  - ext/playpen/playpen.c
76
48
  - lib/playpen.rb
49
+ - lib/playpen/computation_only.rb
50
+ - lib/playpen/no_internet.rb
51
+ - lib/playpen/no_network.rb
52
+ - lib/playpen/no_write.rb
53
+ - lib/playpen/temp_only_write.rb
77
54
  - test/test_playpen.rb
78
- has_rdoc: true
55
+ - .gemtest
79
56
  homepage: http://github.com/tenderlove/playpen
80
57
  licenses: []
81
-
82
58
  post_install_message:
83
- rdoc_options:
59
+ rdoc_options:
84
60
  - --main
85
61
  - README.rdoc
86
- require_paths:
62
+ require_paths:
87
63
  - lib
88
- required_ruby_version: !ruby/object:Gem::Requirement
64
+ required_ruby_version: !ruby/object:Gem::Requirement
89
65
  none: false
90
- requirements:
91
- - - ">="
92
- - !ruby/object:Gem::Version
93
- hash: 3
94
- segments:
95
- - 0
96
- version: "0"
97
- required_rubygems_version: !ruby/object:Gem::Requirement
66
+ requirements:
67
+ - - ! '>='
68
+ - !ruby/object:Gem::Version
69
+ version: '0'
70
+ required_rubygems_version: !ruby/object:Gem::Requirement
98
71
  none: false
99
- requirements:
100
- - - ">="
101
- - !ruby/object:Gem::Version
102
- hash: 3
103
- segments:
104
- - 0
105
- version: "0"
72
+ requirements:
73
+ - - ! '>='
74
+ - !ruby/object:Gem::Version
75
+ version: '0'
106
76
  requirements: []
107
-
108
77
  rubyforge_project: playpen
109
- rubygems_version: 1.3.7
78
+ rubygems_version: 1.8.2
110
79
  signing_key:
111
80
  specification_version: 3
112
81
  summary: Playpen wraps OS X sandbox api with a loving embrace
113
- test_files:
82
+ test_files:
114
83
  - test/test_playpen.rb