ftp_liar 0.1.1 → 0.1.2

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 1a08dfa067a8e790637f70e0f1c1350c155bbf9d
4
- data.tar.gz: 9e591f059c85eb8adeee6ca14280206e29f6b309
3
+ metadata.gz: 46a94e03d4451cb163649ebbca4ea29b357c1b4b
4
+ data.tar.gz: 0682537419402274ba2b73e1a7aa5af171afe1cf
5
5
  SHA512:
6
- metadata.gz: b7fc9e16ac2beb255bc2330d21bc4cf3fc2c747a03bbd65a7fd5c732b4ede55e98e24ff6ae1abff419223dbb46d6dab8f126a88e356ae693b8f22524910bed0b
7
- data.tar.gz: 69b7ffe3638205757968e6cce780480e7c6eece8e6a03000ddbc8b5c8aaedd8f43a7582b44d9644805a1234d95a4161ee9df76e2d92da21dbfcc89cbc6cf54fd
6
+ metadata.gz: eb7fc9663f7137a6764d6af8fc366807341489ecf75f6cfc932263b1b9a03a9002979179a8082b4770b8ba48743820020b3a93d312a5b05b71a93cd5938903ba
7
+ data.tar.gz: d65874cef4501bd231d7ae3768f58c5eb857b71b3f99798b1fe0d69318e907cd201e1367001d182628a0c345bacb6470102a0596bae8cdedb051f9f90746b158
data/README.md CHANGED
@@ -1,8 +1,6 @@
1
1
  # FTPLiar
2
2
 
3
- Welcome to your new gem! In this directory, you'll find the files you need to be able to package up your Ruby library into a gem. Put your Ruby code in the file `lib/ftp_liar`. To experiment with that code, run `bin/console` for an interactive prompt.
4
-
5
- TODO: Delete this and the text above, and describe your gem
3
+ This is experimental gem to simulate Net::FTP object using temporary directory. You use it or your own risk.
6
4
 
7
5
  ## Installation
8
6
 
@@ -21,9 +19,19 @@ Or install it yourself as:
21
19
  $ gem install ftp_liar
22
20
 
23
21
  ## Usage
22
+ Use FTPLiar class with proxy pattern, override interesting class.
24
23
 
25
- TODO: Write usage instructions here
26
-
24
+ ```ruby
25
+ class MyFTP
26
+ def initialize(*args)
27
+ @ftp_liar = FTPLiar::FTPLiar.new
28
+ end
29
+
30
+ def method_missing(name, *args)
31
+ @ftp_liar.send(name, *args)
32
+ end
33
+ end
34
+ ```
27
35
  ## Development
28
36
 
29
37
  After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake rspec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
@@ -1,3 +1,3 @@
1
1
  module FTPLiar
2
- VERSION = "0.1.1"
2
+ VERSION = "0.1.2"
3
3
  end
data/lib/ftp_liar.rb CHANGED
@@ -12,6 +12,9 @@ module FTPLiar
12
12
  FileUtils.cd(Dir.tmpdir)
13
13
  end
14
14
 
15
+ def login(*args)
16
+ end
17
+
15
18
  def getbinaryfile(remotefile, localfile = nil, blocksize = nil)
16
19
  # A simple method that manages to copy a remote file to local
17
20
  FileUtils.cp(remotefile, localfile ? localfile : File.basename(remotefile))
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ftp_liar
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Damian Giebas