.. _commands: ================ Console commands ================ All commands take the identifier of the new site as first argument, as in :file:`config/sites//config.yaml`. .. _command-import: relaunch-redirects:import ========================= Imports the URLs of the old website and checks them against the new site. .. code-block:: bash vendor/bin/typo3 relaunch-redirects:import main https://www.example.org/sitemap.xml vendor/bin/typo3 relaunch-redirects:import main search-console-pages.csv cat urls.txt | vendor/bin/typo3 relaunch-redirects:import main - The source is the URL of a sitemap or URL list, a local file, or :samp:`-` for standard input. .. confval-menu:: :name: import-options :display: table :type: .. confval:: --replace :name: import-replace :type: flag Removes the current list of the site before the import. .. confval:: --no-check :name: import-no-check :type: flag Only imports the URLs. Check them later with :ref:`relaunch-redirects:check `. .. _command-check: relaunch-redirects:check ======================== Checks all imported URLs again and lists the ones that need a decision. .. code-block:: bash vendor/bin/typo3 relaunch-redirects:check main --fail-on-problems .. confval-menu:: :name: check-options :display: table :type: .. confval:: --fail-on-problems :name: check-fail-on-problems :type: flag Exits with code 1 when an old URL is missing or ends in a broken redirect. Use it in a deployment pipeline after the go-live. .. confval:: --limit :name: check-limit :type: integer :default: 50 Maximum number of problems listed in the output. .. _command-create: relaunch-redirects:create ========================= Creates redirects for missing URLs, and fixes broken redirects, whose best suggestion reaches a minimum score. The suggestions below the score are left for a person to decide in the backend module. .. code-block:: bash vendor/bin/typo3 relaunch-redirects:create main --dry-run vendor/bin/typo3 relaunch-redirects:create main .. confval-menu:: :name: create-options :display: table :type: .. confval:: --min-score :name: create-min-score :type: integer :default: 90 Only suggestions with at least this score are used. 100 means the same path, 90 means the page name exists only once on the new site. .. confval:: --status-code :name: create-status-code :type: integer :default: 301 HTTP status code of the new redirects: 301, 302, 303, 307 or 308. .. confval:: --source-host :name: create-source-host :type: string Source host of the new redirects, :samp:`*` for all hosts. By default the host of the old URL is used, or :samp:`*` for paths without host. .. confval:: --dry-run :name: create-dry-run :type: flag Only lists the redirects that would be created. .. _command-export: relaunch-redirects:export ========================= Writes the checked list as CSV. .. code-block:: bash vendor/bin/typo3 relaunch-redirects:export main --filter=attention --output=old-urls.csv .. confval-menu:: :name: export-options :display: table :type: .. confval:: --output :name: export-output :type: string :default: - File to write, :samp:`-` for standard output. .. confval:: --filter :name: export-filter :type: string :default: all Which URLs: :samp:`attention` (missing and broken), :samp:`missing`, :samp:`broken`, :samp:`redirected`, :samp:`ok`, :samp:`unchecked`, :samp:`ignored` or :samp:`all`. .. confval:: --delimiter :name: export-delimiter :type: string :default: , Column delimiter, for example :samp:`;` for Excel with German settings.