Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Command responses #22

Open
Corvisier opened this issue Mar 17, 2014 · 3 comments
Open

Command responses #22

Corvisier opened this issue Mar 17, 2014 · 3 comments

Comments

@Corvisier
Copy link

Hi schickling,

Great package, very useful.
I have a question though, How can we retrive the status of the command?
i.e if the command failed or not? So we an flash a message to the view?

Regards

@schickling
Copy link
Owner

Hi @Corvisier,

if you look into the source you should find what you were looking for:

https://github.com/schickling/laravel-backup/blob/master/src/Schickling/Backup/Commands/BackupCommand.php#L41

@Corvisier
Copy link
Author

Hi @schickling,
Thanks for the fast reply.
I checked the source code before posting hence the question.
I use it like this from the controller:

Artisan::call('db:backup');

I know I need to check for the status so I can display a message that's not the problem.
It's just how do I pass $status to my controller?
Sorry for the noob question...

Regards

@schickling
Copy link
Owner

Well, the plugin wasn't built for that purpose. I'm not sure how Artisan::call handles a response status.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants