Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
drupal
Manage
Activity
Members
Labels
Plan
Wiki
Custom issue tracker
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Model registry
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
project
drupal
Commits
0286c45a
Commit
0286c45a
authored
1 year ago
by
Ted Bowman
Browse files
Options
Downloads
Patches
Plain Diff
delete old auto-update script
parent
6ddd8d0a
No related branches found
No related tags found
2 merge requests
!5011
Issue #2977515: [ignore] Test Package manager core merge
,
!4730
Issue #2977515: [ignore] Test Package manager core merge
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
core/scripts/auto-update
+0
-46
0 additions, 46 deletions
core/scripts/auto-update
with
0 additions
and
46 deletions
core/scripts/auto-update
deleted
100644 → 0
+
0
−
46
View file @
6ddd8d0a
#!/usr/bin/env php
<?php
/**
* @file
* Provides a terminal command for performing automatic updates.
*/
use
Drupal\auto_updates
\Commands\PostApplyCommand
;
use
Drupal\auto_updates
\Commands\RunCommand
;
use
Symfony\Component\Console\Application
;
if
(
PHP_SAPI
!==
'cli'
)
{
throw
new
\RuntimeException
(
'This command must be run from the command line.'
);
}
// Find the autoloader. We know that Automatic Updates is installed somewhere
// in a Drupal code base, so move up the file system until we find
// `./vendor/autoload.php`.
$current_dir
=
__DIR__
;
$previous_dir
=
NULL
;
while
(
$current_dir
!==
$previous_dir
)
{
$file
=
$current_dir
.
'/vendor/autoload.php'
;
if
(
file_exists
(
$file
))
{
/** @var \Composer\Autoload\ClassLoader $autoloader */
$autoloader
=
require_once
$file
;
break
;
}
$previous_dir
=
$current_dir
;
$current_dir
=
dirname
(
$current_dir
);
}
if
(
empty
(
$autoloader
))
{
throw
new
\RuntimeException
(
'The autoloader could not be found. Did you run `composer install`?'
);
}
// Automatic Updates' namespace is not available for autoloading because it is
// a Drupal module, which means Drupal must be booted up in order to access it.
// Since Drupal isn't booted yet, we need to make the autoloader aware of the
// command namespace.
$autoloader
->
addPsr4
(
'Drupal\\auto_updates\\Commands\\'
,
__DIR__
.
'/src/Commands'
);
$application
=
new
Application
(
'Automatic Updates'
,
'3.0.0'
);
$application
->
add
(
new
RunCommand
(
$autoloader
));
$application
->
add
(
new
PostApplyCommand
(
$autoloader
));
$application
->
setDefaultCommand
(
'run'
)
->
run
();
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment