Skip to content

Instantly share code, notes, and snippets.

@nonom
Created July 29, 2022 16:01
Show Gist options
  • Save nonom/61e2ecc57efbf9be8acccfae7112ccb8 to your computer and use it in GitHub Desktop.
Save nonom/61e2ecc57efbf9be8acccfae7112ccb8 to your computer and use it in GitHub Desktop.
Avoid to download translations with the minimal profile on install-clean.
diff --git a/core/profiles/minimal/minimal.module b/core/profiles/minimal/minimal.module
new file mode 100644
index 0000000000..f5abe1de5e
--- /dev/null
+++ b/core/profiles/minimal/minimal.module
@@ -0,0 +1,16 @@
+<?php
+
+/**
+ * @file
+ * Installation profile minimal project.
+ */
+
+/**
+ * Implements hook_install_tasks_alter().
+ */
+function minimal_install_tasks_alter(&$tasks, $install_state): void {
+ // Do not download UI and config translations at installation time.
+ unset($tasks['install_config_download_translations']);
+ unset($tasks['install_import_translations']);
+ unset($tasks['install_finish_translations']);
+}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment