View Single Post
  #2  
Old 11-03-2017, 08:07 AM
 
Triple A Racing Triple A Racing is offline
 

X-Wizard
  
Join Date: Jul 2008
Location: Manchester UK
Posts: 1,028
 

Default Re: Did anyone notice PHP CLI xcart script

Quote:
Originally Posted by cflsystems
As it says in the title - did anyone notice "xcart" script in root of their XC installation?
Yes... the overall attention to fine detail / QA checks / 100% verification pre-upgrade release processes, are all lagging behind the actual XC5 releases, on quite a few different things now. We've said it before a few times, but sorting this area properly is far MORE important than yet more, repetitive marketing waffle and hype for things that are not quite ready. The Modules.php one (and others) we posted about on here previously (and raised a linked bug ticket on). This is THAT script:
PHP Code:
#!/usr/bin/env php
<?php
// vim: set ts=4 sw=4 sts=4 et:

/**
 * Copyright (c) 2011-present Qualiteam software Ltd. All rights reserved.
 * See https://www.x-cart.com/license-agreement.html for license details.
 */

use XLite\Console\Application;

if (
'cli' != PHP_SAPI) {
    exit (
1);
}

define('LC_INCLUDE_ADDITIONAL'true);
require_once (
dirname(__FILE__) . DIRECTORY_SEPARATOR 'top.inc.php');

$header = <<<HEAD
██╗  ██╗      ██████╗ █████╗ ██████╗ ████████╗
╚██╗██╔╝     ██╔════╝██╔══██╗██╔══██╗╚══██╔══╝
 ╚███╔╝█████╗██║     ███████║██████╔╝   ██║   
 ██╔██╗╚════╝██║     ██╔══██║██╔══██╗   ██║   
██╔╝ ██╗     ╚██████╗██║  ██║██║  ██║   ██║   
╚═╝  ╚═╝      ╚═════╝╚═╝  ╚═╝╚═╝  ╚═╝   ╚═╝   

X-Cart
HEAD;

$application = new Application($header, \XLite::XC_VERSION);
$application->run();

\
XLite\Logger::getInstance()->executePostponedLogs();

echo 
PHP_EOL;

exit (
defined('CLI_RESULT_CODE') ? CLI_RESULT_CODE 0);
__________________
Dev Store & Live Store XC Business 5.4.1.35
Server; Ubuntu 22.04.2 LTS (HWE 6.2.0.26.26 Kernel)) / Plesk Obsidian
Nginx 1.20.4 / Apache 2.4.52 (Ubuntu Backported) / MariaDB 10.11.4 / PHP 7.4.33
Reply With Quote