2024-11-27 12:51:32 +00:00
#!/usr/bin/env php
< ? php
/**
* Copyright ( C ) 2010 - 2024 , the Friendica project
* SPDX - FileCopyrightText : 2010 - 2024 the Friendica project
*
* SPDX - License - Identifier : AGPL - 3.0 - or - later
*
2025-01-22 15:43:26 +00:00
* @ deprecated 2025.02 use `bin/console.php jetstream` instead
2024-11-27 12:51:32 +00:00
*/
if ( php_sapi_name () !== 'cli' ) {
header ( $_SERVER [ " SERVER_PROTOCOL " ] . ' 403 Forbidden' );
exit ();
}
// Ensure that Jetstream.php is executed from the base path of the installation
2024-12-28 22:39:20 +00:00
chdir ( dirname ( __DIR__ ));
2024-11-27 12:51:32 +00:00
require dirname ( __DIR__ ) . '/vendor/autoload.php' ;
2025-01-22 15:43:26 +00:00
fwrite ( STDOUT , '`bin/jetstream.php` is deprecated since 2024.02 and will be removed in 5 months, please use `bin/console.php jetstream` instead.' . \PHP_EOL );
2025-01-22 13:47:58 +00:00
// BC: Add console command as second argument
2025-01-01 23:52:48 +01:00
$argv = $_SERVER [ 'argv' ] ? ? [];
array_splice ( $argv , 1 , 0 , " jetstream " );
2025-01-22 13:47:58 +00:00
$_SERVER [ 'argv' ] = $argv ;
2025-01-01 23:52:48 +01:00
2025-01-08 22:59:29 +00:00
$container = \Friendica\Core\DiceContainer :: fromBasePath ( dirname ( __DIR__ ));
2025-01-08 22:20:06 +00:00
$app = \Friendica\App :: fromContainer ( $container );
2025-01-22 13:47:58 +00:00
$app -> processConsole ( $_SERVER );