Deploying Themes to NetSuite Using Gulp Commands

Deploy your custom themes to NetSuite with Gulp commands, enabling website theme activation and customization.

·3 min read·View Oracle Docs

Deploying custom themes is a crucial step in the NetSuite development process, allowing you to activate personalized themes on your website domain after testing and verification. This guide outlines how to deploy a theme using Gulp commands effectively.

How to Deploy Your Theme to NetSuite

To deploy your theme, follow these steps:

  1. Open Command Line: Access your command line or terminal in your local developer environment, navigating to the top-level development directory.

  2. Run Deployment Command: Execute the command below:

    bash
    gulp theme:deploy

    Note: For accounts with account-specific domains on release 2021.2.1 and later, specify your account number to enable access.

  3. Enter Required Information: When prompted, provide the following details, making sure to use only alphanumeric characters without spaces:

    • Authentication ID: Represents your NetSuite account and role. If previously created, the developer tools will use this ID automatically for future commands unless the --to parameter is employed.
    • Account and Role: Specify the account and role used for the new authentication ID.
    • Website: Select the website associated with your domain.
    • Vendor: Enter the vendor name building the theme.
    • Name: Provide a name for your theme, avoiding special characters and spaces.
    • Fantasy Name: Specify how the theme appears in the NetSuite UI.
    • Version: Assign a version number following this format: dd.dd.dd.
    • Description: Write a brief description of your theme for NetSuite's selection interface.
    • Supported Products: Choose relevant products (e.g., SuiteCommerce Online or SCIS).
    • Target Version: Indicate the target versions for the theme, or leave it blank for compatibility with all versions.

When you execute the gulp theme:deploy command, it compiles your theme, updates the manifest.json file, and uploads your files to the NetSuite File Cabinet for activation.

What Happens During Deployment?

The deployment process involves several steps:

  • Files Copying: Custom theme development files are copied into a local DeployDistribution directory.
  • Validation: Your customizations are tested and validated.
  • Manifest Update: The manifest.json file is updated to include necessary overrides.
  • File Upload: Finally, the theme files are uploaded to your NetSuite account. Note: Files are uploaded in chunks (default of 80). You can configure this if needed.

After uploading, an Extension record for the custom theme is created in NetSuite, making it ready for activation.

Next Steps

Once the theme deployment is complete, activate the theme to apply it to your chosen domains. For detailed activation procedures, refer to the guide on Activating Themes and Extensions.

Key Tips:

  • Ensure you have sufficient permissions, typically provided by Administrator and SCDeployer roles.
  • Document any manual changes to your manifest.json, as deploying without the --preserve-manifest option will overwrite them.

Example Scenario

Suppose you download the active SuiteCommerce Base Theme and customize it. Upon testing, you deploy the theme using the gulp theme:deploy command. Following prompts, you enter your new theme's name (e.g., MyCustomTheme1) and ensure all other details are correct before deployment.

Successfully deploying the theme updates the local environment accordingly and prepares it for activation on your site.

Source: This article is based on Oracle's official NetSuite documentation.

Frequently Asked Questions (4)

Do I need to enable any feature flags to deploy themes using Gulp commands in NetSuite?
No specific feature flags need to be enabled to deploy themes using Gulp commands. However, you must provide your account number for accounts with account-specific domains on release 2021.2.1 and later.
What are the necessary details required during the theme deployment process with Gulp?
During theme deployment, provide the Authentication ID, account and role, website, vendor name, theme name, fantasy name, version, description, supported products, and target version.
How does the deployment using Gulp commands affect the manifest.json file?
The deployment process updates the manifest.json file to include necessary overrides. If you do not use the --preserve-manifest option, any manual changes to the manifest.json file may be overwritten.
What roles are recommended for sufficient permissions to deploy themes in NetSuite?
Sufficient permissions for theme deployment are typically provided by the Administrator and SCDeployer roles in NetSuite.
Source: Next Steps Oracle NetSuite Help Center. This article was generated from official Oracle documentation and enriched with additional context and best practices.

Was this article helpful?

More in Commerce

View all Commerce articles →