Giter Club home page Giter Club logo

get_settings's Introduction

Narvar Retailer Settings/Stylesheet script

A command line NodeJS script that pulls current retailer configurations and stylesheets from live Narvar track pages, then writes to files locally, initializes a local git repo, and commits the changes with a timestamp.

Related Projects

Table of Contents

  1. Usage
  2. Requirements
  3. Set up instructions

Usage

The script accepts 4 arguments, only retailer_moniker is required: get-settings <retailer_moniker> <environment> <locale> <parameters>

  • retailer_moniker (required): The retailer moniker that is used in the URL (i.e. https://narvar.com/tracking/<retailer_moniker>)
  • environment (optional): The Narvar environment in which desired track page is hosted (i.e. prod, qa, staging) (default: prod)
  • locale (optional): The ISO locale representation of the desired track page locale (i.e. en_GB, es_US, fr_CA) (default: en_US)
  • parameters (optional): A string of additional parameters to append to the URL (i.e. category=women&preview=true&version=13.0&order=1234) (default: null)

Requirements

  • Node >= 6.13.0
  • Git >= 2.0

Set up Instructions

From the root directory of the repo:

npm install
npm link

Configuration

  • The config.json file is the source for any configurations that can be made to the script
Property Description
PROJECTS_DIR String - The file path to use when writing new configuration updates. Important: DO NOT end this path with a /, this will break the script
should_use_git Boolean - whether or not the script should use git for version control
should_get_styles Boolean - whether or not the script should pull the custom stylesheet for the page
text_editor_shell_cmd String - the command to be used in the terminal to open a file in the text editor (i.e. code <file name>)

get_settings's People

Contributors

jlukenoff avatar

Watchers

James Cloos 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.