Skip to content

Latest commit

 

History

History
93 lines (78 loc) · 3.71 KB

config-cli-subcommands-less-sass.md

File metadata and controls

93 lines (78 loc) · 3.71 KB
group subgroup title menu_title menu_node menu_order functional_areas
configuration-guide
04_CLI
Create symlinks to LESS files
Create symlinks to LESS files
350
Configuration
System
Setup

{% include config/cli-intro.md %}

Create LESS files {#config-cli-subcommands-less-sass}

Use this command to create symlinks to LESS files.

Command options:

bin/magento dev:source-theme:deploy [--type="..."] [--locale="..."] [--area="..."] [--theme="..."] [file1] ... [fileN]

The following table explains this command's parameters and values.

Parameter Value Required?

--type

Type of source files: [less] (default: "less")

Currently, LESS is the only file type supported.

No

--locale

Locale code.

To display the list of locale codes, enter bin/magento info:language:list

No

--area

Area (adminhtml for the administrative area, frontend for the storefront).

No

--theme

Theme name in <VendorName>/<theme name> format. For example, Magento/blank or Magento/backend.

No

<file>

Space-separated list of CSS files to convert to LESS without the .css extension. (Default is css/styles-m css/styles-l, for adminhtml type css/styles css/styles-old)

No

For example, to create LESS files for the frontend theme named VendorName/themeName in the en_US locale using a CSS file named <your Magento install dir>/pub/static/frontend/VendorName/themeName/en_US/css/styles-l.css, enter the following command:

bin/magento dev:source-theme:deploy --type="less" --locale="en_US" --area="frontend" --theme="VendorName/themeName" css/styles-l

The following messages display to confirm success:

Processed Area: frontend, Locale: en_US, Theme: VendorName/themeName, File type: less.
-> css/styles-l.less
Successfully processed.

To create LESS files for the adminhtml, enter the following command:

bin/magento dev:source-theme:deploy --locale="en_US" --area="adminhtml" --theme="Magento/backend" css/styles css/styles-old

Related topics

  • [Manage the cache]({{ page.baseurl }}/config-guide/cli/config-cli-subcommands-cache.html)
  • [Manage the indexers]({{ page.baseurl }}/config-guide/cli/config-cli-subcommands-index.html)
  • [Configure and run cron]({{ page.baseurl }}/config-guide/cli/config-cli-subcommands-cron.html)
  • [Code compiler]({{ page.baseurl }}/config-guide/cli/config-cli-subcommands-compiler.html)
  • [Set the Magento mode]({{ page.baseurl }}/config-guide/cli/config-cli-subcommands-mode.html)
  • [URN highlighter]({{ page.baseurl }}/config-guide/cli/config-cli-subcommands-urn.html)
  • [Dependency reports]({{ page.baseurl }}/config-guide/cli/config-cli-subcommands-depen.html)
  • [Translation dictionaries and language packages]({{ page.baseurl }}/config-guide/cli/config-cli-subcommands-i18n.html)
  • [Deploy static view files]({{ page.baseurl }}/config-guide/cli/config-cli-subcommands-static-view.html)
  • [Run unit tests]({{ page.baseurl }}/config-guide/cli/config-cli-subcommands-test.html)
  • [Convert layout XML files]({{ page.baseurl }}/config-guide/cli/config-cli-subcommands-layout-xml.html)
  • [Generate data for performance testing]({{ page.baseurl }}/config-guide/cli/config-cli-subcommands-perf-data.html)