Code Monkey home page Code Monkey logo

gasify's Introduction

gasify NPM version Build Status Dependency Status Coverage percentage Greenkeeper badge

Browserify plugin for Google Apps Script.

About

In Google Apps Script, it must be top level function declaration that entry point called from google.script.run. When gasify detect a function assignment expression to global object. it generate a top level function declaration statement.

example

main.js:

var echo = require('./echo');
global.echo = echo;

echo.js:

module.exports = function(message) {
  return message;
}

build:

$ browserify main.js -p gasify -o Code.gs

Code.gs

var global = this;function echo() {
}(function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){
module.exports = function(message) {
  return message;
};

},{}],2:[function(require,module,exports){
(function (global){
var echo = require('./echo');
global.echo = echo;

}).call(this,typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
},{"./echo":1}]},{},[2]);

Installation

$ npm install gasify

Usage

CLI

$ browserify main.js -p gasify -o Code.gs

Options

The following options can be set via the API or command-line:

comment {Boolean}: If true then generate a top level function declaration statement with comment. Default is true.

gasify's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

gasify's Issues

[DepShield] (CVSS 7.4) Vulnerability due to usage of lodash.get:4.4.2

Vulnerabilities

DepShield reports that this application's usage of lodash.get:4.4.2 results in the following vulnerability(s):


Occurrences

lodash.get:4.4.2 is a transitive dependency introduced by the following direct dependency(s):

xo:0.23.0
        └─ eslint-plugin-unicorn:6.0.1
              └─ eslint-ast-utils:1.1.0
                    └─ lodash.get:4.4.2

This is an automated GitHub Issue created by Sonatype DepShield. Details on managing GitHub Apps, including DepShield, are available for personal and organization accounts. Please submit questions or feedback about DepShield to the Sonatype DepShield Community.

[DepShield] (CVSS 7.4) Vulnerability due to usage of lodash.flattendeep:4.4.0

Vulnerabilities

DepShield reports that this application's usage of lodash.flattendeep:4.4.0 results in the following vulnerability(s):


Occurrences

lodash.flattendeep:4.4.0 is a transitive dependency introduced by the following direct dependency(s):

nyc:13.1.0
        └─ caching-transform:2.0.0
              └─ package-hash:2.0.0
                    └─ lodash.flattendeep:4.4.0

This is an automated GitHub Issue created by Sonatype DepShield. Details on managing GitHub Apps, including DepShield, are available for personal and organization accounts. Please submit questions or feedback about DepShield to the Sonatype DepShield Community.

[DepShield] (CVSS 8.2) Vulnerability due to usage of handlebars:4.1.2

Vulnerabilities

DepShield reports that this application's usage of handlebars:4.1.2 results in the following vulnerability(s):


Occurrences

handlebars:4.1.2 is a transitive dependency introduced by the following direct dependency(s):

nyc:14.1.1
        └─ istanbul-reports:2.2.4
              └─ handlebars:4.1.2

This is an automated GitHub Issue created by Sonatype DepShield. Details on managing GitHub Apps, including DepShield, are available for personal and organization accounts. Please submit questions or feedback about DepShield to the Sonatype DepShield Community.

[DepShield] (CVSS 7.5) Vulnerability due to usage of set-value:2.0.0

Vulnerabilities

DepShield reports that this application's usage of set-value:2.0.0 results in the following vulnerability(s):


Occurrences

set-value:2.0.0 is a transitive dependency introduced by the following direct dependency(s):

xo:0.24.0
        └─ globby:9.2.0
              └─ fast-glob:2.2.6
                    └─ micromatch:3.1.10
                          └─ snapdragon:0.8.2
                                └─ base:0.11.2
                                      └─ cache-base:1.0.1
                                            └─ set-value:2.0.0

This is an automated GitHub Issue created by Sonatype DepShield. Details on managing GitHub Apps, including DepShield, are available for personal and organization accounts. Please submit questions or feedback about DepShield to the Sonatype DepShield Community.

Sourcemaps not supported

When browserify is used with sourcemaps enabled, gasify doesn't adjust the sourcemaps, so the sourcemaps are incorrect and offset by the number of lines added.

[DepShield] (CVSS 7.4) Vulnerability due to usage of lodash.isequal:4.5.0

Vulnerabilities

DepShield reports that this application's usage of lodash.isequal:4.5.0 results in the following vulnerability(s):


Occurrences

lodash.isequal:4.5.0 is a transitive dependency introduced by the following direct dependency(s):

xo:0.23.0
        └─ lodash.isequal:4.5.0

This is an automated GitHub Issue created by Sonatype DepShield. Details on managing GitHub Apps, including DepShield, are available for personal and organization accounts. Please submit questions or feedback about DepShield to the Sonatype DepShield Community.

An in-range update of nyc is breaking the build 🚨

Version 11.7.1 of nyc was just published.

Branch Build failing 🚨
Dependency nyc
Current Version 11.7.0
Type devDependency

This version is covered by your current version range and after updating it in your project the build failed.

nyc is a devDependency of this project. It might not break your production code or affect downstream projects, but probably breaks your build or test tools, which may prevent deploying or publishing.

Status Details
  • continuous-integration/travis-ci/push The Travis CI build failed Details

Commits

The new version differs by 2 commits.

  • 5e40c7c chore(release): 11.7.1
  • 5c0adb5 chore: explicit upgrade of istanbul-reports (#816)

See the full diff

FAQ and help

There is a collection of frequently asked questions. If those don’t help, you can always ask the humans behind Greenkeeper.


Your Greenkeeper Bot 🌴

An in-range update of coveralls is breaking the build 🚨

Version 3.0.1 of coveralls was just published.

Branch Build failing 🚨
Dependency coveralls
Current Version 3.0.0
Type devDependency

This version is covered by your current version range and after updating it in your project the build failed.

coveralls is a devDependency of this project. It might not break your production code or affect downstream projects, but probably breaks your build or test tools, which may prevent deploying or publishing.

Status Details
  • continuous-integration/travis-ci/push The Travis CI build failed Details

Release Notes Additional CI support

Maintenance:

Commits

The new version differs by 9 commits.

  • e7ae2bf version bump; logger test fix
  • 9b892bf Verbose use log level debug
  • 9cfb496 Add buildkite support (#177)
  • aa8c257 Done callback waits for unlink in testRepoTokenDetection to prevent race condition (#179)
  • 18c71c2 Fix a mistype in tests: fs.exists -> fs.existsSync (#184)
  • bd667c6 Add Semaphore support (#180)
  • 10d8b3e Update examples to include Jest (#183)
  • 720ee7c Add license (#175)
  • 83ff2cb Add mention about AppVeyor to the README (#164)

See the full diff

FAQ and help

There is a collection of frequently asked questions. If those don’t help, you can always ask the humans behind Greenkeeper.


Your Greenkeeper Bot 🌴

[DepShield] (CVSS 7.5) Vulnerability due to usage of mocha:5.0.5

Vulnerabilities

DepShield reports that this application's usage of mocha:5.0.5 results in the following vulnerability(s):


Occurrences

mocha:5.0.5 is a transitive dependency introduced by the following direct dependency(s):

coveralls:3.0.8
        └─ cobertura-parse:1.0.5
              └─ mocha:5.0.5

This is an automated GitHub Issue created by Sonatype DepShield. Details on managing GitHub Apps, including DepShield, are available for personal and organization accounts. Please submit questions or feedback about DepShield to the Sonatype DepShield Community.

[DepShield] (CVSS 7.4) Vulnerability due to usage of lodash.camelcase:4.3.0

Vulnerabilities

DepShield reports that this application's usage of lodash.camelcase:4.3.0 results in the following vulnerability(s):


Occurrences

lodash.camelcase:4.3.0 is a transitive dependency introduced by the following direct dependency(s):

xo:0.23.0
        └─ eslint-plugin-unicorn:6.0.1
              └─ lodash.camelcase:4.3.0

This is an automated GitHub Issue created by Sonatype DepShield. Details on managing GitHub Apps, including DepShield, are available for personal and organization accounts. Please submit questions or feedback about DepShield to the Sonatype DepShield Community.

[DepShield] (CVSS 7.4) Vulnerability due to usage of lodash.throttle:4.1.1

Vulnerabilities

DepShield reports that this application's usage of lodash.throttle:4.1.1 results in the following vulnerability(s):


Occurrences

lodash.throttle:4.1.1 is a transitive dependency introduced by the following direct dependency(s):

tap:13.0.3
        └─ treport:0.3.0
              └─ ink:2.1.1
                    └─ lodash.throttle:4.1.1

This is an automated GitHub Issue created by Sonatype DepShield. Details on managing GitHub Apps, including DepShield, are available for personal and organization accounts. Please submit questions or feedback about DepShield to the Sonatype DepShield Community.

[DepShield] (CVSS 7.5) Vulnerability due to usage of debug:2.6.9

Vulnerabilities

DepShield reports that this application's usage of debug:2.6.9 results in the following vulnerability(s):


Occurrences

debug:2.6.9 is a transitive dependency introduced by the following direct dependency(s):

tap:13.1.11
        └─ import-jsx:2.0.0
              └─ babel-core:6.26.3
                    └─ babel-traverse:6.26.0
                          └─ debug:2.6.9
                    └─ debug:2.6.9
        └─ tap-mocha-reporter:4.0.1
              └─ debug:2.6.9

xo:0.24.0
        └─ eslint-plugin-import:2.17.2
              └─ debug:2.6.9
              └─ eslint-import-resolver-node:0.3.2
                    └─ debug:2.6.9
              └─ eslint-module-utils:2.4.0
                    └─ debug:2.6.9
        └─ globby:9.2.0
              └─ fast-glob:2.2.6
                    └─ micromatch:3.1.10
                          └─ extglob:2.0.4
                                └─ expand-brackets:2.1.4
                                      └─ debug:2.6.9
                          └─ snapdragon:0.8.2
                                └─ debug:2.6.9

This is an automated GitHub Issue created by Sonatype DepShield. Details on managing GitHub Apps, including DepShield, are available for personal and organization accounts. Please submit questions or feedback about DepShield to the Sonatype DepShield Community.

Parser error for files that require() json content

Trying to require the module moment-timezone causes a parse error in esprima. After some debugging, it appears to happen when gasify attempts to parse a JSON file that was required. Gasify is receiving the raw JSON instead of the processed version from browserify that prepends modules.export= to the beginning.

The error in gasify is in collect(). It's injecting itself too early in the pipeline at the 'deps' stage, which happens before the JSON is processed.

Moving to a later stage like 'labels' (or even just up to 'json') fixes the problem.

Version 10 of node.js has been released

Version 10 of Node.js (code name Dubnium) has been released! 🎊

To see what happens to your code in Node.js 10, Greenkeeper has created a branch with the following changes:

  • Added the new Node.js version to your .travis.yml

If you’re interested in upgrading this repo to Node.js 10, you can open a PR with these changes. Please note that this issue is just intended as a friendly reminder and the PR as a possible starting point for getting your code running on Node.js 10.

More information on this issue

Greenkeeper has checked the engines key in any package.json file, the .nvmrc file, and the .travis.yml file, if present.

  • engines was only updated if it defined a single version, not a range.
  • .nvmrc was updated to Node.js 10
  • .travis.yml was only changed if there was a root-level node_js that didn’t already include Node.js 10, such as node or lts/*. In this case, the new version was appended to the list. We didn’t touch job or matrix configurations because these tend to be quite specific and complex, and it’s difficult to infer what the intentions were.

For many simpler .travis.yml configurations, this PR should suffice as-is, but depending on what you’re doing it may require additional work or may not be applicable at all. We’re also aware that you may have good reasons to not update to Node.js 10, which is why this was sent as an issue and not a pull request. Feel free to delete it without comment, I’m a humble robot and won’t feel rejected 🤖


FAQ and help

There is a collection of frequently asked questions. If those don’t help, you can always ask the humans behind Greenkeeper.


Your Greenkeeper Bot 🌴

[DepShield] (CVSS 7.4) Vulnerability due to usage of lodash.memoize:3.0.4

Vulnerabilities

DepShield reports that this application's usage of lodash.memoize:3.0.4 results in the following vulnerability(s):


Occurrences

lodash.memoize:3.0.4 is a transitive dependency introduced by the following direct dependency(s):

browserify:16.2.3
        └─ browser-pack:6.1.0
              └─ combine-source-map:0.8.0
                    └─ lodash.memoize:3.0.4

This is an automated GitHub Issue created by Sonatype DepShield. Details on managing GitHub Apps, including DepShield, are available for personal and organization accounts. Please submit questions or feedback about DepShield to the Sonatype DepShield Community.

An in-range update of tap is breaking the build 🚨

Version 11.1.1 of tap was just published.

Branch Build failing 🚨
Dependency tap
Current Version 11.1.0
Type devDependency

This version is covered by your current version range and after updating it in your project the build failed.

tap is a devDependency of this project. It might not break your production code or affect downstream projects, but probably breaks your build or test tools, which may prevent deploying or publishing.

Status Details
  • continuous-integration/travis-ci/push The Travis CI build failed Details

Commits

The new version differs by 4 commits.

  • 95faf6c 11.1.1
  • 283c8e6 Handle EPIPE better in exceptional edge cases
  • b727234 Fix obscure edge case when this.results is not set
  • 13073a7 docs: correct 100 PR link

See the full diff

FAQ and help

There is a collection of frequently asked questions. If those don’t help, you can always ask the humans behind Greenkeeper.


Your Greenkeeper Bot 🌴

[DepShield] (CVSS 7.4) Vulnerability due to usage of lodash.snakecase:4.1.1

Vulnerabilities

DepShield reports that this application's usage of lodash.snakecase:4.1.1 results in the following vulnerability(s):


Occurrences

lodash.snakecase:4.1.1 is a transitive dependency introduced by the following direct dependency(s):

xo:0.23.0
        └─ eslint-plugin-unicorn:6.0.1
              └─ lodash.snakecase:4.1.1

This is an automated GitHub Issue created by Sonatype DepShield. Details on managing GitHub Apps, including DepShield, are available for personal and organization accounts. Please submit questions or feedback about DepShield to the Sonatype DepShield Community.

[DepShield] (CVSS 7.4) Vulnerability due to usage of lodash.mergewith:4.6.1

Vulnerabilities

DepShield reports that this application's usage of lodash.mergewith:4.6.1 results in the following vulnerability(s):


Occurrences

lodash.mergewith:4.6.1 is a transitive dependency introduced by the following direct dependency(s):

xo:0.23.0
        └─ lodash.mergewith:4.6.1

This is an automated GitHub Issue created by Sonatype DepShield. Details on managing GitHub Apps, including DepShield, are available for personal and organization accounts. Please submit questions or feedback about DepShield to the Sonatype DepShield Community.

An in-range update of browserify is breaking the build 🚨

☝️ Greenkeeper’s updated Terms of Service will come into effect on April 6th, 2018.

Version 16.2.0 of browserify was just published.

Branch Build failing 🚨
Dependency browserify
Current Version 16.1.1
Type devDependency

This version is covered by your current version range and after updating it in your project the build failed.

browserify is a devDependency of this project. It might not break your production code or affect downstream projects, but probably breaks your build or test tools, which may prevent deploying or publishing.

Status Details
  • continuous-integration/travis-ci/push The Travis CI build failed Details

Release Notes v16.2.0

update the browser versions of vm-browserify and string_decoder.

string_decoder updates to the Node 8+ API.
vm-browserify replaces an unlicensed dependency by an MIT one.

#1829

Commits

The new version differs by 5 commits.

  • 00cc377 16.2.0
  • 7005b6e Merge pull request #1829 from browserify/deps
  • e333b14 Merge pull request #1827 from browserify/fix-cert
  • 03ffac9 ci: Disable certificate check for very old npm
  • 9345e21 Update string_decoder and vm builtin modules

See the full diff

FAQ and help

There is a collection of frequently asked questions. If those don’t help, you can always ask the humans behind Greenkeeper.


Your Greenkeeper Bot 🌴

[DepShield] (CVSS 7.5) Vulnerability due to usage of set-value:0.4.3

Vulnerabilities

DepShield reports that this application's usage of set-value:0.4.3 results in the following vulnerability(s):


Occurrences

set-value:0.4.3 is a transitive dependency introduced by the following direct dependency(s):

xo:0.24.0
        └─ globby:9.2.0
              └─ fast-glob:2.2.6
                    └─ micromatch:3.1.10
                          └─ snapdragon:0.8.2
                                └─ base:0.11.2
                                      └─ cache-base:1.0.1
                                            └─ union-value:1.0.0
                                                  └─ set-value:0.4.3

This is an automated GitHub Issue created by Sonatype DepShield. Details on managing GitHub Apps, including DepShield, are available for personal and organization accounts. Please submit questions or feedback about DepShield to the Sonatype DepShield Community.

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.