title: How to run task scheduler locally on Laravel 7?
body: <p>I want to learn how to use task scheduler in Laravel 7</p>
  <p>According to the documentation, I created a task that should send out a test message to the mail on Mondays at 16:00. Judging by the documentation for local development, there is no need to add a cron entry. I just run the command <code>php artisan schedule:work</code> get this error <code>Command &quot;schedule:work&quot; is not defined.</code> Where am I making a mistake?</p>
  <pre><code> protected function schedule(Schedule $schedule)
    {
     $schedule-&gt;call(function () {
         $test = 'test';
         $email = Emails::where('id', 1)-&gt;first();
  
         Mail::to($email)-&gt;send(new TestMail($test));
      })-&gt;mondays()-&gt;at('16:00');
  }
  </code></pre>
  <p>After I tried to add the line  <code>* * * * * cd /public_html/my_project &amp;&amp; php artisan schedule:run &gt;&gt; /dev/null 2&gt;&amp;1</code> but got the following message <code>bash: README_CI.md: command not found</code></p>