update tagline and ensure required settings are provided for sftp
This commit is contained in:
parent
757272d6af
commit
62248cb099
4 changed files with 9 additions and 8 deletions
|
@ -1,5 +1,5 @@
|
||||||
Middleman Deploy - Deploy a [middleman](http://middlemanapp.com/)
|
Middleman Deploy - Deploy a [middleman](http://middlemanapp.com/)
|
||||||
built site over rsync, ftp, or git (e.g. gh-pages on github).
|
built site over rsync, ftp, sftp, or git (e.g. gh-pages on github).
|
||||||
|
|
||||||
[![Build Status](https://secure.travis-ci.org/tvaughan/middleman-deploy.png)](http://travis-ci.org/tvaughan/middleman-deploy)
|
[![Build Status](https://secure.travis-ci.org/tvaughan/middleman-deploy.png)](http://travis-ci.org/tvaughan/middleman-deploy)
|
||||||
|
|
||||||
|
|
|
@ -22,7 +22,7 @@ module Middleman
|
||||||
true
|
true
|
||||||
end
|
end
|
||||||
|
|
||||||
desc "deploy", "Deploy build directory to a remote host via rsync or git"
|
desc "deploy [options]", Middleman::Deploy::TAGLINE
|
||||||
method_option "clean",
|
method_option "clean",
|
||||||
:type => :boolean,
|
:type => :boolean,
|
||||||
:aliases => "-c",
|
:aliases => "-c",
|
||||||
|
@ -75,9 +75,9 @@ activate :deploy do |deploy|
|
||||||
deploy.branch = "some-other-branch-name"
|
deploy.branch = "some-other-branch-name"
|
||||||
end
|
end
|
||||||
|
|
||||||
# To deploy the build directory to a remote host via ftp:
|
# To deploy the build directory to a remote host via ftp or sftp:
|
||||||
activate :deploy do |deploy|
|
activate :deploy do |deploy|
|
||||||
deploy.method = :ftp
|
deploy.method = :ftp or :sftp
|
||||||
# host, user, passwword and path *must* be set
|
# host, user, passwword and path *must* be set
|
||||||
deploy.host = "ftp.example.com"
|
deploy.host = "ftp.example.com"
|
||||||
deploy.user = "tvaughan"
|
deploy.user = "tvaughan"
|
||||||
|
@ -110,9 +110,9 @@ EOF
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
if (options.method == :ftp)
|
if (options.method == :ftp || options.method == :sftp)
|
||||||
if (!options.host || !options.user || !options.password || !options.path)
|
if (!options.host || !options.user || !options.password || !options.path)
|
||||||
print_usage_and_die "The ftp deploy method requires host, user, password, and path to be set."
|
print_usage_and_die "The ftp and sftp deploy methods requires host, user, password, and path to be set."
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
@ -2,5 +2,6 @@ module Middleman
|
||||||
module Deploy
|
module Deploy
|
||||||
PACKAGE = "middleman-deploy"
|
PACKAGE = "middleman-deploy"
|
||||||
VERSION = "0.0.12"
|
VERSION = "0.0.12"
|
||||||
|
TAGLINE = "Deploy a middleman built site over rsync, ftp, sftp, or git (e.g. gh-pages on github)."
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
@ -9,8 +9,8 @@ Gem::Specification.new do |s|
|
||||||
s.authors = ["Tom Vaughan"]
|
s.authors = ["Tom Vaughan"]
|
||||||
s.email = ["thomas.david.vaughan@gmail.com"]
|
s.email = ["thomas.david.vaughan@gmail.com"]
|
||||||
s.homepage = "http://tvaughan.github.com/middleman-deploy/"
|
s.homepage = "http://tvaughan.github.com/middleman-deploy/"
|
||||||
s.summary = %q{Deploy a middleman built site over rsync, ftp, or git (e.g. gh-pages on github).}
|
s.summary = Middleman::Deploy::TAGLINE
|
||||||
s.description = %q{Deploy a middleman built site over rsync, ftp, or git (e.g. gh-pages on github).}
|
s.description = Middleman::Deploy::TAGLINE
|
||||||
s.license = "MIT"
|
s.license = "MIT"
|
||||||
|
|
||||||
s.files = `git ls-files`.split("\n")
|
s.files = `git ls-files`.split("\n")
|
||||||
|
|
Loading…
Reference in a new issue