Download the PHP package alex-kalanis/kw_clipr without Composer

On this page you can find all versions of the php package alex-kalanis/kw_clipr. 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 kw_clipr

kw_clipr

Build Status Scrutinizer Code Quality Latest Stable Version Minimum PHP Version Downloads License Code Coverage

CLI Processor

Basic framework for running your scripts from CLI in a bit prettier package. It calls task from predefined sources and allows them to run. Based on django cli and private CliC. You can use it as base for running your own scripts like regular checks or menial tasks. All that with simplified write to CLI output. All that with coloring and runable from web interface, *nix or Windows CLI. As extra you will get a table engine which creates output in markdown syntax.

Command line query is simple: . It uses kw_input for determination which params came. So with a bit of tinkering you can also pass regular files to tasks for some processing.

The tasks returns Unix codes and Clipr pass them back to caller. See the IStatuses interface for their description.

PHP Installation

Direct usage

Install and set PHP on target machine. Then download this project and by following steps fill it by tasks suited for your needs.

1.) Download clipr somewhere / install via Composer

2a.) For *nix check if your base script with bootstrap can be executed

2b.) For Windows check if you have PHP installed and in %PATH%

3.) Run Clipr from /bin without parameters to test if it works; You must be inside the project dir.

4a.) Here you probably copy clipr initial file to somewhere for better access for users.

4b.) Then it's necessary to include your own autoloader in that file. Preset one probably will not work.

4c.) And you need to set correct paths to basic clipr tasks, mainly due different Composer paths.

5.) Call your clipr initial file and check if it works again. Try Listing for check tasks.

6.) Make another directory with your tasks and fill them with classes based on your use-case.

6.) Call them and check if everything runs

Composer

(Refer to Composer Documentation if you are not familiar with composer)

PHP Usage

Each task is stored in preset directories in which it's possible to find them the fast way. The paths are set in initial file. And each task is subclass of kw_clipr\Tasks\ATask, which allows to write outputs and call params.

For running task simply call

For creating your tasks you must create some directory where they will be, create some tasks with correct namespacing and add that root namespace into Clipr init file to paths. If you use DI autoloading for your classes then you also need to specify that autoloader in Clipr init file - in example there is already a prepared commented-out place. I saw this with DI of DB or other services accessing classes.

Clipr tasks can be set into tree, so you can separate them by some of your logic. Not need to fill one directory with one huge list of tasks.

For beginning I advise to just copy one of tasks and play with it.

Changes

Caveats

In default setup it contains subparts of kw_autoload and kw_inputs projects - both are necessary to run without other dependencies. If you install this via Composer you'll see kw_input twice and kw_autoload as extra weight. But that's okay. kw_autoload doesn't see composer files if they aren't in predefined paths where kw_autoload can look for them. For default run it isn't necessary to use the whole machine of Composer and it has been developed without it.

And at last - there is NO dependency injection support by default. You must set it by yourself. Because that usually means at least installing Composer and that's the thing I want to avoid. Usual DI libraries are very dependent on Composer. And the whole PSR has been made with Composer in mind. Also original project CliC had no DI support. Version 2 has better support for DI, but it is not running by default. And default tasks do not have it.


All versions of kw_clipr with dependencies

PHP Build Version
Package Version
Requires ext-mbstring Version *
alex-kalanis/kw_input Version >=3.0 <4
alex-kalanis/kw_locks Version >=3.0 <4
alex-kalanis/kw_paths Version >=4.0 <5
php Version >=7.4.0
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 alex-kalanis/kw_clipr contains the following files

Loading the files please wait ....