Coder Social home page Coder Social logo

Comments (8)

rstacruz avatar rstacruz commented on May 18, 2024

To be in line with Rake's usage, I believe should be rake -f script.rb.

The modification here will be very minimal, this line would just have to be suppressed if -f is given.

from mina.

rstacruz avatar rstacruz commented on May 18, 2024

This one-code-line edit should do the trick:

diff --git a/bin/mina b/bin/mina
index 6379630..05c1ca7 100755
--- a/bin/mina
+++ b/bin/mina
@@ -26,7 +26,10 @@ Rake.application.instance_eval do
   standard_exception_handling do
     # Initialize Rake and make it think it's Mina.
     init 'mina'
-    @rakefiles = ['Minafile', 'config/deploy.rb']
+
+    # Assume different default Rakefiles.
+    # (The only way a @rakefiles can have multiple values is if -f isn't specified.)
+    @rakefiles = ['Minafile', 'config/deploy.rb']  if @rakefiles.size > 1

     # Workaround: Rake 0.9+ doesn't record task descriptions unless it's needed.
     # Need it for 'mina help'

from mina.

rstacruz avatar rstacruz commented on May 18, 2024

This is in v0.1.1 now--just do mina -f file.rb. Does it suit your requirements?

from mina.

sosedoff avatar sosedoff commented on May 18, 2024

Yep, totally. I cant believe i missed that -f option in rake.

from mina.

garethrees avatar garethrees commented on May 18, 2024

To confirm, does this mean I can use mina on a central deployment server which does not have access to the source code and then use it like so:

mina -f apps/app1.rb
# => Deploys app 1

mina -f apps/app2.rb
# => Deploys app 2

from mina.

rstacruz avatar rstacruz commented on May 18, 2024

Indeed you may, @garethrees.

from mina.

sosedoff avatar sosedoff commented on May 18, 2024

Yeah, the syntax to deploy would be:

mina -f apps/app1.rb deploy
mina -f apps/app2.rb deploy

Im using it the same way

from mina.

garethrees avatar garethrees commented on May 18, 2024

Amazing, thanks both

from mina.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.