middleman-deploy: Error with Middleman 4.2 and middleman-deploy 1.0

impossible to launch middleman server. I’have this error when I launch the middleman server :

WARN: Unresolved specs during Gem::Specification.reset: rack (< 3, >= 1.4.5) tilt (< 3, >= 1.4.1, ~> 2.0) parallel (>= 0) activesupport (< 5.1, >= 3.1, >= 4.2) addressable (~> 2.3) sass (>= 3.4) uglifier (~> 3.0) hashie (~> 3.4) concurrent-ruby (~> 1.0) WARN: Clearing out unresolved specs. Please report a bug if this causes problems. /usr/local/opt/rbenv/versions/2.3.2/lib/ruby/gems/2.3.0/gems/middleman-core-4.2.1/lib/middleman-core/extensions.rb:96:in load': Tried to activate old-style extension: deploy. They are no longer supported. (RuntimeError) from /usr/local/opt/rbenv/versions/2.3.2/lib/ruby/gems/2.3.0/gems/middleman-core-4.2.1/lib/middleman-core/extensions.rb:127:in block in load_settings’ from /usr/local/opt/rbenv/versions/2.3.2/lib/ruby/gems/2.3.0/gems/middleman-core-4.2.1/lib/middleman-core/extensions.rb:125:in each' from /usr/local/opt/rbenv/versions/2.3.2/lib/ruby/gems/2.3.0/gems/middleman-core-4.2.1/lib/middleman-core/extensions.rb:125:in load_settings’ from /usr/local/opt/rbenv/versions/2.3.2/lib/ruby/gems/2.3.0/gems/middleman-core-4.2.1/lib/middleman-core/extension_manager.rb:12:in initialize' from /usr/local/opt/rbenv/versions/2.3.2/lib/ruby/gems/2.3.0/gems/middleman-core-4.2.1/lib/middleman-core/application.rb:263:in new’ from /usr/local/opt/rbenv/versions/2.3.2/lib/ruby/gems/2.3.0/gems/middleman-core-4.2.1/lib/middleman-core/application.rb:263:in initialize' from /usr/local/opt/rbenv/versions/2.3.2/lib/ruby/gems/2.3.0/gems/middleman-cli-4.2.1/bin/middleman:49:in new’ from /usr/local/opt/rbenv/versions/2.3.2/lib/ruby/gems/2.3.0/gems/middleman-cli-4.2.1/bin/middleman:49:in <top (required)>' from /usr/local/opt/rbenv/versions/2.3.2/bin/middleman:22:in load’ from /usr/local/opt/rbenv/versions/2.3.2/bin/middleman:22:in `<main>’

Steps to reproduce the problem (from a clean middleman installation)

$ gem install middleman $ middleman init add ‘’’ gem ‘middleman-deploy’, ‘~> 1.0’ ‘’’ in gemfile $ bundle install add in config.rb :

activate :deploy do |deploy|
  deploy.deploy_method = :git
  # Optional Settings
  # deploy.remote   = 'custom-remote' # remote name or git url, default: origin
  # deploy.branch   = 'custom-branch' # default: gh-pages
  # deploy.strategy = :submodule      # commit strategy: can be :force_push or :submodule, default: :force_push
  # deploy.commit_message = 'custom-message'      # commit message (can be empty), default: Automated commit at `timestamp` by middleman-deploy `version`
end""

$ middleman server –> error

Additional information

  • Ruby version: ruby 2.3.2p217 (2016-11-15 revision 56796) [x86_64-darwin16]
  • Middleman version: 4.2
  • OS version: iOS 10.12.4

my code is : https://github.com/hugobarthelemy/combidav

About this issue

  • Original URL
  • State: open
  • Created 7 years ago
  • Reactions: 12
  • Comments: 16

Most upvoted comments

works for me, but I had to ensure the following:

gem 'middleman-deploy', '~> 2.0.0.pre.alpha'

and

activate :deploy do |deploy|
  deploy.deploy_method = :git

as mentioned in other threads …

@joneslee85 how’s everything going? do you need help with this project?

Interesting, I thought the master branch is broken. I am using the alpha branch, which seems to work:

gem 'middleman-deploy',       '~> 2.0.0.pre.alpha'

My config looks like:

activate :deploy do |deploy|
  deploy.deploy_method = :rsync
  deploy.host          = 'user@hostname'
  deploy.path          = '/path/to/files'
  deploy.build_before  = true
end

Glad to hear yours is working!

I am using gem 'middleman-deploy', git: 'https://github.com/middleman-contrib/middleman-deploy', branch: 'master' with this:

activate :deploy do |deploy|
  deploy.build_before   = true
  deploy.deploy_method  = :git
  deploy.branch         = 'TEST-BRANCH'
end``` and it is working