Git Product home page Git Product logo

suitescriptgenerator's Introduction

SuiteScript Generator

Contributor Covenant License: MIT

Overview

This project is designed to help aid in the development of NetSuite SuiteScript projects. Using the CLI, you can automatically create new SuiteScripts with the AMD module boilerplate included.

NOTE: This project is NOT intended to replace the SuiteCloud Developer Framework and the project structure that is created using that tool. This project is intended to be used with the SDF to generate the files specific to your project, after the SDF generates the project strcture.

Features

The CLI does the following:

  • Create a new file
  • Write a Copyright message to the file, if supplied
  • Write the SuiteScript script type, if supplied
  • Write the SuiteScript API version
  • Write the AMD Module Definition with SuiteScript modules (N/*), if supplied

Options

Short Long Description Default Constraints
-h --help Displays the help message N/A N/A
-f --filename The filename to be created N/A Required, File extension must be .js
-c --copyright The text file where the copyright message is stored No copyright File extension must be .txt
-s --scripttype The type of SuiteScript to be created No type Must be a valid SuiteScript type
-a --apiversion The SuiteScript API version to use 2.1 Must be either 2.0, 2.x, or 2.1
-m --modules The SuiteScript API modules to import No modules Must be a valid NetSuite SuiteScript module

Usage

The output files from the following commands are visible in the examples directory.

To create a simple file skeleton: suitescript -f basic.js or suitescript --filename basic.js

To create a file with a specific version: suitescript -f versioned.js -v 2.0

To create a file for a specific script type: suitescript -f typed.js -t MapReduce

To create a file with imported modules: suitescript -f imports.js -m record search

To create a file with a copyright doc comment: suitescript -f copyright.js -c copyright.txt

And any combination: suitescript -f combo.js -c copyright.txt -v 2.x -m record search -t client

References

Please refer to the NetSuite guides for valid SuiteScript types and modules, and for more information on developing your SuiteScript files and projects.

Guides:

Roadmap

  • Support reading an input file for generating entire projects
  • Support custom modules with local or absolute paths
  • Support custom names for module arguments
  • Support skeletons for known SuiteScript entry points when applicable

Contributing

Please open an issue before making a pull request.

Please update tests as appropriate.

License

MIT

suitescriptgenerator's People

Contributors

donovandicks avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.