Download the PHP package saficodes/laravel-hostkit without Composer

On this page you can find all versions of the php package saficodes/laravel-hostkit. 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 laravel-hostkit

laravel-hostkit

A Laravel Artisan package for developers who deploy to shared hosting (Hostinger, Namecheap, cPanel, etc.) where the web root is the project root — not public/.

On shared hosting you can't point the domain to /public, so everything inside public/index.php, .htaccess, assets, everything — needs to live at the project root instead. This package moves all public/ contents back and forth safely, including automatically patching index.php paths and securing sensitive files via .htaccess.


The Problem

You don't want to manually move files and patch paths every time you switch environments. This package automates that — with backups, rollback, conflict detection, and automatic .htaccess security.


Installation

Auto-discovery registers the service provider. No config file needed.


Commands

Command What it does
php artisan env:status Show current mode and what's in public/ vs root
php artisan env:productionise Move all public/ contents → project root (for shared hosting)
php artisan env:localise Move everything back → public/ (for local dev)
php artisan env:backup --type=pre-deploy Create a named backup snapshot
php artisan env:reset --to=previous Restore from a backup

Options


Typical workflow

1. Check current state

2. Before pushing to shared hosting

3. Back to local dev after pulling

4. Something went wrong — roll back


What gets moved

Everything inside public/ is moved to the project root, including:

Skipped automatically:


Security

When you run env:productionise, the package automatically adds rules to .htaccess that block web access to sensitive files and directories:

Blocked files: .env, artisan, composer.json, composer.lock, package.json, phpunit.xml, vite.config.js/ts

Blocked directories: app/, bootstrap/, config/, database/, lang/, resources/, routes/, storage/, tests/, vendor/

These rules are automatically removed when you run env:localise.


How mode is detected

The package uses a state file (.hostkit.json) to track the current mode and which items were moved. If no state file exists, it falls back to checking where index.php lives.

State Condition
local public/index.php exists (standard Laravel)
production index.php at project root (moved from public/)
conflict index.php found in BOTH locations
unknown index.php not found anywhere

Backups

Every switch command automatically creates a previous backup before making any changes. The very first switch also saves an original backup. You can create additional named backups at any time:

Backups are stored in .hostkit-backups/ at the project root. Add this to .gitignore.


Safety


Add to .gitignore


Requirements


License

MIT © M Safi Abdullah


All versions of laravel-hostkit with dependencies

PHP Build Version
Package Version
Requires php Version ^8.1
illuminate/support Version ^10.0|^11.0|^12.0|^13.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 saficodes/laravel-hostkit contains the following files

Loading the files please wait ...