infrataster-plugin-ftp 0.0.2 → 0.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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: ffcf5b9c72cc6731ef714b4fab74c8e722891eba1b22060cc9ffb57491937171
4
- data.tar.gz: b72e46c6df7ae55c72be93906ebc5e3fa93678f1b6fe30144a509298b0be244a
3
+ metadata.gz: b80b5aeb7ac9b3473f558e366430209645249fdf23acde9a9afdbe16e9b52402
4
+ data.tar.gz: a11891f0c2b9f39889cada25f9d56934716706c4291c674947883289ebd832fa
5
5
  SHA512:
6
- metadata.gz: 5b8181ce237dbe42b2dcd411638162223f96a57526cc99fc0a65c6aba2b48819453d2e87741d7f17d0b8a3e2478c9bf5fd571364e0cff520596fa0b59be24621
7
- data.tar.gz: fad8ce9ba70a69c1fc97a607b04f2679698a2792c6bf465ce26d7338cb4aa543ecf1ad45749cb1d7b2c266e14e4f3f0e4fecd9979ccfe3cca7fe6229167aa28e
6
+ metadata.gz: 80176500071deeef4305c4884f244dfd8c99eb003023e1612e3a6f535a513083c70556a21738ead8fc2d6b5d4812a9226c829c6f795210b3c4870f59ee262982
7
+ data.tar.gz: a9a23195825cbc814fa11fe96bffe9e3ed5e1c42af7c9de87eb1e92736051a3ae6db87db5598ee8d70ee41248f95aef09add2f66bf638b809cba0bdddcb20bdf
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- infrataster-plugin-ftp (0.0.2)
4
+ infrataster-plugin-ftp (0.0.3)
5
5
  infrataster
6
6
 
7
7
  GEM
data/README.md CHANGED
@@ -1,8 +1,6 @@
1
1
  # Infrataster::Plugin::Ftp
2
2
  [![Build Status](https://travis-ci.org/inokappa/infrataster-plugin-ftp.svg?branch=master)](https://travis-ci.org/inokappa/infrataster-plugin-ftp)
3
3
 
4
- 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/infrataster/plugin/ftp`. To experiment with that code, run `bin/console` for an interactive prompt.
5
-
6
4
  ## Installation
7
5
 
8
6
  Add this line to your application's Gemfile:
@@ -21,14 +19,45 @@ Or install it yourself as:
21
19
 
22
20
  ## Usage
23
21
 
24
- TODO: Write usage instructions here
25
-
26
- ## Development
27
-
28
- After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
22
+ ```ruby
23
+ require 'spec_helper'
24
+
25
+ describe server(:ftp_server) do
26
+ describe ftp('welcome') do
27
+ it 'check accessible' do
28
+ expect(result.chomp).to eq('230 Login successful.')
29
+ end
30
+ end
31
+
32
+ describe ftp('pwd') do
33
+ it 'check `chroot` enabled' do
34
+ expect(result).to eq('/')
35
+ end
36
+ end
37
+
38
+ describe ftp('mkdir test_dir') do
39
+ it 'run `mkdir`' do
40
+ expect(result).to include '/test_dir'
41
+ end
42
+ end
43
+
44
+ describe ftp('ls') do
45
+ it 'run ls' do
46
+ expect(result).to include 'sample.txt'
47
+ end
48
+ end
49
+ end
50
+ ```
29
51
 
30
- To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).
52
+ You can specify `server.address`, username, password by options passed to Infrataster::Server.define:
31
53
 
54
+ ```ruby
55
+ Infrataster::Server.define(
56
+ :ftp_server,
57
+ '192.168.0.6',
58
+ ftp: { user: 'ftpuser', pass: 'supersecret', passive: true },
59
+ )
60
+ ```
32
61
  ## Contributing
33
62
 
34
63
  Bug reports and pull requests are welcome on GitHub at https://github.com/[USERNAME]/infrataster-plugin-ftp.
@@ -1,7 +1,7 @@
1
1
  module Infrataster
2
2
  module Plugin
3
3
  module Ftp
4
- VERSION = "0.0.2"
4
+ VERSION = "0.0.3"
5
5
  end
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: infrataster-plugin-ftp
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.2
4
+ version: 0.0.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Yohei Kawahara