Download the PHP package trig/laracron without Composer

On this page you can find all versions of the php package trig/laracron. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package laracron

Laracron

This tool adds a capability to manage your Cron-based CLI tasks via simple JSON configuration. Once configured it allows you to control you scheduled tasks without plain old Cron interface. Inspired by Laravel Task Scheduling

Installation

Manager designed to be used as phar executable, so you need to build it first. Clone project first:

Then compile Phar executable with the following command:

After this step you will find laracron.phar file in the current directory. Then you need to add only one Cron task:

That's all it needs.

Usage

Now you can configure manager for your project needs, just copy laracron.phar file to your project root folder. Here are default configuration file (laracron.json):

Here is the brief description for each configuration option:

scheduledJobs

Is the main configuration option, needed for scheduling you CLI commands, it is a JSON object with keys standing for Cron job definition of specific method names. You can see full list on Task Scheduling page. Here are some examples:

Method Description
->cron(' *'); Run the task on a custom Cron schedule
->everyMinute(); Run the task every minute
->everyFiveMinutes(); Run the task every five minutes
->everyTenMinutes(); Run the task every ten minutes
->everyFifteenMinutes(); Run the task every fifteen minutes
->everyThirtyMinutes(); Run the task every thirty minutes
->hourly(); Run the task every hour
->daily(); Run the task every day at midnight
->weekly(); Run the task every week
->monthly(); Run the task every month
->quarterly(); Run the task every quarter
->yearly(); Run the task every year

So, based on the above description, let's define some simple task and schedule it to run each 15 minutes, just omit object access operator and parenthesis for the definition:

You may have noticed, that parametrized definitions is not supported (e.g ->weeklyOn(1, '8:00');) however it fully covered by Cron syntax.

cache.default

Stands for caching engine name can be one of file or redis

log_to (optional)

Relative path to log file where it will log execution output, be aware that log file is not rotated

cache.prefix

Used as prefix to cache entries it creates

cache.stores.file

Configuration for file cache engine

cache.stores.redis

Configuration for Redis cache engine


All versions of laracron with dependencies

PHP Build Version
Package Version
Requires illuminate/console Version ^5.7
illuminate/container Version ^5.7
illuminate/events Version ^5.7
illuminate/cache Version ^5.7
illuminate/filesystem Version ^5.7
dragonmantank/cron-expression Version ^2.2
symfony/console Version ^4.1
symfony/process Version ^4.1
illuminate/redis Version ^5.7
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package trig/laracron contains the following files

Loading the files please wait ....