Skip to content

Commit

Permalink
fixed package generation
Browse files Browse the repository at this point in the history
  • Loading branch information
alexnsolo committed Mar 21, 2018
1 parent ca1bd3e commit be1a992
Show file tree
Hide file tree
Showing 42 changed files with 457 additions and 403 deletions.
2 changes: 2 additions & 0 deletions .gitignore
@@ -0,0 +1,2 @@
node_modules
npm-debug.log
52 changes: 52 additions & 0 deletions git_push.sh
@@ -0,0 +1,52 @@
#!/bin/sh
# ref: https://help.github.com/articles/adding-an-existing-project-to-github-using-the-command-line/
#
# Usage example: /bin/sh ./git_push.sh wing328 swagger-petstore-perl "minor update"

git_user_id=$1
git_repo_id=$2
release_note=$3

if [ "$git_user_id" = "" ]; then
git_user_id="intrinio"
echo "[INFO] No command line input provided. Set \$git_user_id to $git_user_id"
fi

if [ "$git_repo_id" = "" ]; then
git_repo_id="javascript-sdk"
echo "[INFO] No command line input provided. Set \$git_repo_id to $git_repo_id"
fi

if [ "$release_note" = "" ]; then
release_note="No release notes for this build"
echo "[INFO] No command line input provided. Set \$release_note to $release_note"
fi

# Initialize the local directory as a Git repository
git init

# Adds the files in the local repository and stages them for commit.
git add .

# Commits the tracked changes and prepares them to be pushed to a remote repository.
git commit -m "$release_note"

# Sets the new remote
git_remote=`git remote`
if [ "$git_remote" = "" ]; then # git remote not defined

if [ "$GIT_TOKEN" = "" ]; then
echo "[INFO] \$GIT_TOKEN (environment variable) is not set. Using the Git credential in your environment."
git remote add origin https://github.com/${git_user_id}/${git_repo_id}.git
else
git remote add origin https://${git_user_id}:${GIT_TOKEN}@github.com/${git_user_id}/${git_repo_id}.git
fi

fi

git pull origin master

# Pushes (Forces) the changes in the local repository up to the remote repository
echo "Git pushing to https://github.com/${git_user_id}/${git_repo_id}.git"
git push origin master 2>&1 | grep -v 'To https'

2 changes: 1 addition & 1 deletion package.json
Expand Up @@ -3,7 +3,7 @@
"version": "0.0.1",
"description": "Access the Intrinio API",
"license": "GPLv3",
"main": "src/invoker/index.js",
"main": "src/index.js",
"scripts": {
"test": "./node_modules/mocha/bin/mocha --recursive"
},
Expand Down
8 changes: 4 additions & 4 deletions src/ApiClient.js
Expand Up @@ -31,15 +31,15 @@
'use strict';

/**
* @module invoker/ApiClient
* @module ApiClient
* @version 0.0.1
*/

/**
* Manages low level client-server communications, parameter marshalling, etc. There should not be any need for an
* application to use this class directly - the *Api and model classes provide the public API for the service. The
* contents of this file should be regarded as internal but are documented for completeness.
* @alias module:invoker/ApiClient
* @alias module:ApiClient
* @class
*/
var exports = function() {
Expand Down Expand Up @@ -261,7 +261,7 @@
/**
* Builds a string representation of an array-type actual parameter, according to the given collection format.
* @param {Array} param An array parameter.
* @param {module:invoker/ApiClient.CollectionFormatEnum} collectionFormat The array element separator strategy.
* @param {module:ApiClient.CollectionFormatEnum} collectionFormat The array element separator strategy.
* @returns {String|Array} A string representation of the supplied collection, using the specified delimiter. Returns
* <code>param</code> as is if <code>collectionFormat</code> is <code>multi</code>.
*/
Expand Down Expand Up @@ -578,7 +578,7 @@

/**
* The default API client implementation.
* @type {module:invoker/ApiClient}
* @type {module:ApiClient}
*/
exports.instance = new exports();

Expand Down
78 changes: 39 additions & 39 deletions src/invoker/api/CompanyApi.js → src/api/CompanyApi.js

Large diffs are not rendered by default.

18 changes: 9 additions & 9 deletions src/invoker/api/DataPointApi.js → src/api/DataPointApi.js
Expand Up @@ -16,7 +16,7 @@
(function(root, factory) {
if (typeof define === 'function' && define.amd) {
// AMD. Register as an anonymous module.
define(['invoker/ApiClient', 'invoker/model/DataPointNumber', 'invoker/model/DataPointText'], factory);
define(['ApiClient', 'model/DataPointNumber', 'model/DataPointText'], factory);
} else if (typeof module === 'object' && module.exports) {
// CommonJS-like environments that support module.exports, like Node.
module.exports = factory(require('../ApiClient'), require('../model/DataPointNumber'), require('../model/DataPointText'));
Expand All @@ -32,16 +32,16 @@

/**
* DataPoint service.
* @module invoker/api/DataPointApi
* @module api/DataPointApi
* @version 0.0.1
*/

/**
* Constructs a new DataPointApi.
* @alias module:invoker/api/DataPointApi
* @alias module:api/DataPointApi
* @class
* @param {module:invoker/ApiClient} [apiClient] Optional API client implementation to use,
* default to {@link module:invoker/ApiClient#instance} if unspecified.
* @param {module:ApiClient} [apiClient] Optional API client implementation to use,
* default to {@link module:ApiClient#instance} if unspecified.
*/
var exports = function(apiClient) {
this.apiClient = apiClient || ApiClient.instance;
Expand All @@ -53,7 +53,7 @@
* Returns a numeric value for the given &#x60;item&#x60; and the entity with the given &#x60;identifier&#x60;
* @param {String} identifier An identifier for an entity such as a Company, Security, Index, etc (Ticker, FIGI, ISIN, CUSIP, CIK, LEI, Intrinio ID)
* @param {String} item An Intrinio data tag or other item
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:invoker/model/DataPointNumber} and HTTP response
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/DataPointNumber} and HTTP response
*/
this.getDataPointNumberWithHttpInfo = function(identifier, item) {
var postBody = null;
Expand Down Expand Up @@ -99,7 +99,7 @@
* Returns a numeric value for the given &#x60;item&#x60; and the entity with the given &#x60;identifier&#x60;
* @param {String} identifier An identifier for an entity such as a Company, Security, Index, etc (Ticker, FIGI, ISIN, CUSIP, CIK, LEI, Intrinio ID)
* @param {String} item An Intrinio data tag or other item
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:invoker/model/DataPointNumber}
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/DataPointNumber}
*/
this.getDataPointNumber = function(identifier, item) {
return this.getDataPointNumberWithHttpInfo(identifier, item)
Expand All @@ -114,7 +114,7 @@
* Returns a text value for the given &#x60;item&#x60; and the entity with the given &#x60;identifier&#x60;
* @param {String} identifier An identifier for an entity such as a Company, Security, Index, etc (Ticker, FIGI, ISIN, CUSIP, CIK, LEI, Intrinio ID)
* @param {String} item An Intrinio data tag or other item
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:invoker/model/DataPointText} and HTTP response
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/DataPointText} and HTTP response
*/
this.getDataPointTextWithHttpInfo = function(identifier, item) {
var postBody = null;
Expand Down Expand Up @@ -160,7 +160,7 @@
* Returns a text value for the given &#x60;item&#x60; and the entity with the given &#x60;identifier&#x60;
* @param {String} identifier An identifier for an entity such as a Company, Security, Index, etc (Ticker, FIGI, ISIN, CUSIP, CIK, LEI, Intrinio ID)
* @param {String} item An Intrinio data tag or other item
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:invoker/model/DataPointText}
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/DataPointText}
*/
this.getDataPointText = function(identifier, item) {
return this.getDataPointTextWithHttpInfo(identifier, item)
Expand Down
22 changes: 11 additions & 11 deletions src/invoker/api/FilingApi.js → src/api/FilingApi.js
Expand Up @@ -16,7 +16,7 @@
(function(root, factory) {
if (typeof define === 'function' && define.amd) {
// AMD. Register as an anonymous module.
define(['invoker/ApiClient', 'invoker/model/Filing'], factory);
define(['ApiClient', 'model/Filing'], factory);
} else if (typeof module === 'object' && module.exports) {
// CommonJS-like environments that support module.exports, like Node.
module.exports = factory(require('../ApiClient'), require('../model/Filing'));
Expand All @@ -32,16 +32,16 @@

/**
* Filing service.
* @module invoker/api/FilingApi
* @module api/FilingApi
* @version 0.0.1
*/

/**
* Constructs a new FilingApi.
* @alias module:invoker/api/FilingApi
* @alias module:api/FilingApi
* @class
* @param {module:invoker/ApiClient} [apiClient] Optional API client implementation to use,
* default to {@link module:invoker/ApiClient#instance} if unspecified.
* @param {module:ApiClient} [apiClient] Optional API client implementation to use,
* default to {@link module:ApiClient#instance} if unspecified.
*/
var exports = function(apiClient) {
this.apiClient = apiClient || ApiClient.instance;
Expand All @@ -56,7 +56,7 @@
* @param {Date} opts.startDate Filed on or after the given date
* @param {Date} opts.endDate Filed before or after the given date
* @param {String} opts.nextPage Gets the next page of data from a previous API call
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link Array.<module:invoker/model/Filing>} and HTTP response
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link Array.<module:model/Filing>} and HTTP response
*/
this.filterFilingsWithHttpInfo = function(company, opts) {
opts = opts || {};
Expand Down Expand Up @@ -104,7 +104,7 @@
* @param {Date} opts.startDate Filed on or after the given date
* @param {Date} opts.endDate Filed before or after the given date
* @param {String} opts.nextPage Gets the next page of data from a previous API call
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link Array.<module:invoker/model/Filing>}
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link Array.<module:model/Filing>}
*/
this.filterFilings = function(company, opts) {
return this.filterFilingsWithHttpInfo(company, opts)
Expand All @@ -118,7 +118,7 @@
* Get All Filings
* @param {Object} opts Optional parameters
* @param {String} opts.nextPage Gets the next page of data from a previous API call
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link Array.<module:invoker/model/Filing>} and HTTP response
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link Array.<module:model/Filing>} and HTTP response
*/
this.getAllFilingsWithHttpInfo = function(opts) {
opts = opts || {};
Expand Down Expand Up @@ -153,7 +153,7 @@
* Get All Filings
* @param {Object} opts Optional parameters
* @param {String} opts.nextPage Gets the next page of data from a previous API call
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link Array.<module:invoker/model/Filing>}
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link Array.<module:model/Filing>}
*/
this.getAllFilings = function(opts) {
return this.getAllFilingsWithHttpInfo(opts)
Expand All @@ -166,7 +166,7 @@
/**
* Get a Filing by ID
* @param {String} id The Intrinio ID of the Filing
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:invoker/model/Filing} and HTTP response
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/Filing} and HTTP response
*/
this.getFilingByIdWithHttpInfo = function(id) {
var postBody = null;
Expand Down Expand Up @@ -204,7 +204,7 @@
/**
* Get a Filing by ID
* @param {String} id The Intrinio ID of the Filing
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:invoker/model/Filing}
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/Filing}
*/
this.getFilingById = function(id) {
return this.getFilingByIdWithHttpInfo(id)
Expand Down

0 comments on commit be1a992

Please sign in to comment.