io-afc 0.0.3.2

Sign up to get free protection for your applications and to get access to all the features.
data/Gemfile ADDED
@@ -0,0 +1,8 @@
1
+ source 'https://rubygems.org'
2
+
3
+ # Specify your gem's dependencies in io-afc.gemspec
4
+ gemspec
5
+
6
+ gem 'rspec'
7
+ gem 'pry'
8
+ gem 'pry-nav'
data/Gemfile.lock ADDED
@@ -0,0 +1,38 @@
1
+ PATH
2
+ remote: .
3
+ specs:
4
+ io-afc (0.0.3.2)
5
+
6
+ GEM
7
+ remote: https://rubygems.org/
8
+ specs:
9
+ coderay (1.0.9)
10
+ diff-lcs (1.2.4)
11
+ method_source (0.8.1)
12
+ pry (0.9.12.2)
13
+ coderay (~> 1.0.5)
14
+ method_source (~> 0.8)
15
+ slop (~> 3.4)
16
+ pry-nav (0.2.3)
17
+ pry (~> 0.9.10)
18
+ rake (10.0.4)
19
+ rspec (2.13.0)
20
+ rspec-core (~> 2.13.0)
21
+ rspec-expectations (~> 2.13.0)
22
+ rspec-mocks (~> 2.13.0)
23
+ rspec-core (2.13.1)
24
+ rspec-expectations (2.13.0)
25
+ diff-lcs (>= 1.1.3, < 2.0)
26
+ rspec-mocks (2.13.1)
27
+ slop (3.4.5)
28
+
29
+ PLATFORMS
30
+ ruby
31
+
32
+ DEPENDENCIES
33
+ bundler (~> 1.3)
34
+ io-afc!
35
+ pry
36
+ pry-nav
37
+ rake
38
+ rspec
data/LICENSE.txt ADDED
@@ -0,0 +1,22 @@
1
+ Copyright (c) 2013 Toshiyuki Suzumura
2
+
3
+ MIT License
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining
6
+ a copy of this software and associated documentation files (the
7
+ "Software"), to deal in the Software without restriction, including
8
+ without limitation the rights to use, copy, modify, merge, publish,
9
+ distribute, sublicense, and/or sell copies of the Software, and to
10
+ permit persons to whom the Software is furnished to do so, subject to
11
+ the following conditions:
12
+
13
+ The above copyright notice and this permission notice shall be
14
+ included in all copies or substantial portions of the Software.
15
+
16
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
19
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
20
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
21
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
22
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,45 @@
1
+ # IO::AFC
2
+
3
+ Access to the file system of iOS devices from Ruby.
4
+
5
+ Required the following components:
6
+ - libimobiledevice
7
+
8
+
9
+ ## Installation
10
+
11
+ Install 'libimobiledevice'.
12
+
13
+ $ brew install libimobiledevice
14
+
15
+
16
+ Add this line to your application's Gemfile:
17
+
18
+ gem 'io-afc'
19
+
20
+ And then execute:
21
+
22
+ $ bundle
23
+
24
+ Or install it yourself as:
25
+
26
+ $ gem install io-afc
27
+
28
+
29
+ ## Usage
30
+
31
+ IO::AFC.connect{|afc|
32
+ afc.open("/hello", IO::WRONLY){|f|
33
+ f.write "Hello, world"
34
+ }
35
+ }
36
+
37
+
38
+
39
+ ## Contributing
40
+
41
+ 1. Fork it
42
+ 2. Create your feature branch (`git checkout -b my-new-feature`)
43
+ 3. Commit your changes (`git commit -am 'Add some feature'`)
44
+ 4. Push to the branch (`git push origin my-new-feature`)
45
+ 5. Create new Pull Request
data/Rakefile ADDED
@@ -0,0 +1,38 @@
1
+ require 'bundler/gem_tasks'
2
+
3
+ desc "Build extension."
4
+ task :ext do
5
+ sh <<-__SCRIPT__
6
+ cd ext/io/afc/
7
+ ruby extconf.rb
8
+ make
9
+ __SCRIPT__
10
+ end
11
+
12
+
13
+ desc "Clean."
14
+ task :clean do
15
+ sh <<-__SCRIPT__
16
+ pushd ext/io/afc
17
+ make clean
18
+ rm -f Makefile
19
+ popd
20
+ pushd io-afc.xcodeproj
21
+ rm -rf project.xcworkspace xcuserdata
22
+ popd
23
+ __SCRIPT__
24
+ end
25
+
26
+
27
+ desc "Debug console."
28
+ task :console do
29
+ Rake::Task["ext"].invoke
30
+ system "pry -I./ext -I./lib -r io/afc"
31
+ end
32
+
33
+
34
+ desc "Run test."
35
+ task :test do
36
+ Rake::Task["ext"].invoke
37
+ system "rspec spec/*_spec.rb"
38
+ end
@@ -0,0 +1,7 @@
1
+ RUBY_VERSION = ruby-1.9.3-p429
2
+ RUBY_INCLUDE_PATH = $(HOME)/.rvm/rubies/$(RUBY_VERSION)/include/ruby-1.9.1 $(HOME)/.rvm/rubies/$(RUBY_VERSION)/include/ruby-1.9.1/x86_64-darwin11.4.2
3
+ RUBY_LDFLAGS = -L$(HOME)/.rvm/rubies/$(RUBY_VERSION)/lib -lruby
4
+
5
+ EXT_INCLUDE_PATH = $(RUBY_INCLUDE_PATH) /usr/local/Cellar/libimobiledevice/1.1.5/include /usr/local/Cellar/libplist/1.10/include /usr/local/Cellar/libxml2/2.9.1/include/libxml2 /usr/local/Cellar/usbmuxd/1.0.8/include
6
+
7
+ EXT_LDFLAGS = $(RUBY_LDFLAGS) -L/usr/local/Cellar/libimobiledevice/1.1.5/lib -L/usr/local/Cellar/libplist/1.10/lib -L/usr/local/Cellar/usbmuxd/1.0.8/lib -limobiledevice -lplist -lusbmuxd -lssl -lcrypto -lz
@@ -0,0 +1,7 @@
1
+ require 'mkmf'
2
+
3
+ $CPPFLAGS="`pkg-config --cflags libimobiledevice-1.0`"
4
+ $LDFLAGS="`pkg-config --libs libimobiledevice-1.0`"
5
+ pkg_config("libimobiledevice-1.0")
6
+
7
+ create_makefile("io/afc/afc_base")