From a7035a56fc9d4030f58d9245858663f77df7d16d Mon Sep 17 00:00:00 2001 From: Phil Kunz Date: Thu, 9 Jun 2016 01:38:22 +0200 Subject: [PATCH] update dependencies and restructure code --- .gitlab-ci.yml | 37 +++++++++++++++++++ .travis.yml | 12 ------ package.json | 9 +++-- ts/index.ts | 13 +++---- ts/projectinfi.classes.git.ts | 0 ...info.npm.ts => projectinfo.classes.npm.ts} | 6 +-- ts/typings.json | 7 ---- 7 files changed, 50 insertions(+), 34 deletions(-) create mode 100644 .gitlab-ci.yml delete mode 100644 .travis.yml create mode 100644 ts/projectinfi.classes.git.ts rename ts/{projectinfo.npm.ts => projectinfo.classes.npm.ts} (94%) delete mode 100644 ts/typings.json diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml new file mode 100644 index 0000000..2d1c8c1 --- /dev/null +++ b/.gitlab-ci.yml @@ -0,0 +1,37 @@ +image: hosttoday/ht-docker-node:npmci + +stages: +- test +- release +- page + +testLEGACY: + stage: test + script: + - npmci test legacy + tags: + - docker + allow_failure: true + +testLTS: + stage: test + script: + - npmci test lts + tags: + - docker + +testSTABLE: + stage: test + script: + - npmci test stable + tags: + - docker + +release: + stage: release + script: + - npmci publish + only: + - tags + tags: + - docker \ No newline at end of file diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 8e5d534..0000000 --- a/.travis.yml +++ /dev/null @@ -1,12 +0,0 @@ -language: node_js -node_js: -- 'v4.2.6' -- 'stable' -deploy: - provider: npm - email: npm@lossless.digital - api_key: - secure: G2ZQYeDEokGCWQcXeT9SJ4aUF0uZ41B1kM9WD7hZKMGM5hzbGSTXjd/bLWf2HfujvN9FWQYVv0y5OpbRck4xTuEDBPmC5AqXCfrtNj77n151VLO0cF4+Ya1l8OQWvw13hX+cux8UfxRVHUAxUt7CoW3q6FBO/vt1Mvo9u9ucxKdB4QHXmPdq8TwuFusPJYC+l2LdWiaSCEz2LpnyrDf6OjLl2Bt+8rID3Ikbi+5yXWv/n7bfiXyIlpJX/i4Efh/mqsSWp+ziVWaSdKdpYMFPxqyOfqQ/kjbzLCwdR72cD3+UoJPdGQ46Vq3ncZRq3KighWkYRzN76EOTI/quzfcAoz5CekETPh419lPuqs2w8wEeE2oP0yCCSH1SG1ljH8ASrADWsoHzWyVa8c/ovzWMOc3hgLey6xgbYVar0sC94bjjqJh8Y5qOak4idOpI/SXf0UT1TkirZTGfdSgRzg/E1Zqj262sxLeIv0yHsbnzgwUduj6PjfLztgLVAGO13csxksUSiKxT8Mbbqozv1sdz/0SgoZTMYfZSO5kYdBCqguJkJdEj1Dr4tM/0ca+mugHibavQxPJiWqnfNqxdlmywpzPHPHe5G2wzba2W62l3yPHF4rJBJuUi35ddWWOkAN1g9D2NHlByWfqF+WYRuTv1DPlw7ZpmgEVPPUlBPhC5YO8= - on: - tags: true - repo: pushrocks/projectinfo diff --git a/package.json b/package.json index 04b5154..490bb58 100644 --- a/package.json +++ b/package.json @@ -8,7 +8,7 @@ }, "repository": { "type": "git", - "url": "git+https://github.com/pushrocks/projectinfo.git" + "url": "git+https://gitlab.com/pushrocks/projectinfo.git" }, "keywords": [ "project", @@ -20,9 +20,9 @@ "author": "Lossless GmbH", "license": "MIT", "bugs": { - "url": "https://github.com/pushrocks/projectinfo/issues" + "url": "https://gitlab.com/pushrocks/projectinfo/issues" }, - "homepage": "https://github.com/pushrocks/projectinfo#readme", + "homepage": "https://gitlab.com/pushrocks/projectinfo#readme", "devDependencies": { "npmts": "^3.1.2", "should": "^8.2.2" @@ -30,6 +30,7 @@ "dependencies": { "q": "^1.4.1", "smartfile": "0.0.11", - "smartstring": "0.0.2" + "smartstring": "0.0.2", + "typings-global": "^1.0.3" } } diff --git a/ts/index.ts b/ts/index.ts index a9a16be..80d1ccc 100644 --- a/ts/index.ts +++ b/ts/index.ts @@ -2,10 +2,11 @@ import plugins = require("./projectinfo.plugins"); var projectinfo:any = {}; -//classes -import ProjectinfoNPM = require("./projectinfo.npm"); -projectinfo.npm = function(cwdArg,optionsArg){ - return new ProjectinfoNPM(cwdArg,optionsArg); +//npm +import {ProjectinfoNpm} from "./projectinfo.classes.npm"; +export {ProjectinfoNpm} from "./projectinfo.classes.npm"; +export let npm = function(cwdArg,optionsArg){ + return new ProjectinfoNpm(cwdArg,optionsArg); }; //quick functions @@ -24,6 +25,4 @@ projectinfo.git = function(){ projectinfo.mojo = function(){ }; -*/ - -export = projectinfo; \ No newline at end of file +*/ \ No newline at end of file diff --git a/ts/projectinfi.classes.git.ts b/ts/projectinfi.classes.git.ts new file mode 100644 index 0000000..e69de29 diff --git a/ts/projectinfo.npm.ts b/ts/projectinfo.classes.npm.ts similarity index 94% rename from ts/projectinfo.npm.ts rename to ts/projectinfo.classes.npm.ts index 21fffc1..b01e870 100644 --- a/ts/projectinfo.npm.ts +++ b/ts/projectinfo.classes.npm.ts @@ -1,6 +1,6 @@ /// import plugins = require("./projectinfo.plugins"); -class ProjectinfoNPM { +export class ProjectinfoNpm { packageJson; name:string; version:string; @@ -24,6 +24,4 @@ class ProjectinfoNPM { }; }; -} - -export = ProjectinfoNPM; \ No newline at end of file +} \ No newline at end of file diff --git a/ts/typings.json b/ts/typings.json deleted file mode 100644 index 57323dd..0000000 --- a/ts/typings.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "ambientDependencies": { - "node": "github:DefinitelyTyped/DefinitelyTyped/node/node.d.ts", - "mocha": "github:Bartvds/tsd-deftools/typings/DefinitelyTyped/mocha/mocha.d.ts", - "colors": "github:DefinitelyTyped/DefinitelyTyped/colors/colors.d.ts" - } -}