Skip to content

Add project subcommands #6

Description

@bomberstudios

I have a somehow complex environment I need to run for my project (think Sphinx, delayed_job, etc...) and a nice addition for project would be to add project subcommands, so you can run stuff when starting a work session and stop stuff when finishing.

I.e, if I have this .project file:

:workflows:
  :default:
    :start:
      - mate %path
      - mysql_start # Start MySQL
      - cd %path && rake ts:start #start Sphinx
      - cd %path && rails server
    :stop:
      - mysql_stop # Stop MySQL
      - cd %path && rake ts:stop #stop Sphinx
:projects:
  :myproject:
    :path: /path/to/project
    :workflow: default

then running

$ project myproject start

would open TextMate, bring MySQL and Sphinx up, and start the Rails server, and

$ project myproject stop

would stop MySQL and Sphinx.

(The 'start' command would be default, so project myproject would be equivalent to project myproject start)

I may have a go at it, but I make no promises... : )

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions