fix(core): update

This commit is contained in:
Philipp Kunz 2020-03-27 13:40:03 +00:00
parent a84368fd42
commit 0a1bf06048
29 changed files with 1814 additions and 2230 deletions

21
.gitignore vendored

@ -1,3 +1,20 @@
.nogit/
# artifacts
coverage/
public/
pages/
# installs
node_modules/ node_modules/
.settings/
.idea/ # caches
.yarn/
.cache/
.rpt2_cache
# builds
dist/
dist_*/
# custom

127
.gitlab-ci.yml Normal file

@ -0,0 +1,127 @@
# gitzone ci_default
image: registry.gitlab.com/hosttoday/ht-docker-node:npmci
cache:
paths:
- .npmci_cache/
key: '$CI_BUILD_STAGE'
stages:
- security
- test
- release
- metadata
# ====================
# security stage
# ====================
mirror:
stage: security
script:
- npmci git mirror
tags:
- lossless
- docker
- notpriv
audit:
image: registry.gitlab.com/hosttoday/ht-docker-node:npmci
stage: security
script:
- npmci npm prepare
- npmci command npm install --ignore-scripts
- npmci command npm config set registry https://registry.npmjs.org
- npmci command npm audit --audit-level=high
tags:
- lossless
- docker
- notpriv
# ====================
# test stage
# ====================
testStable:
stage: test
script:
- npmci npm prepare
- npmci node install stable
- npmci npm install
- npmci npm test
coverage: /\d+.?\d+?\%\s*coverage/
tags:
- lossless
- docker
- priv
testBuild:
stage: test
script:
- npmci npm prepare
- npmci node install stable
- npmci npm install
- npmci command npm run build
coverage: /\d+.?\d+?\%\s*coverage/
tags:
- lossless
- docker
- notpriv
release:
stage: release
script:
- npmci node install stable
- npmci npm publish
only:
- tags
tags:
- lossless
- docker
- notpriv
# ====================
# metadata stage
# ====================
codequality:
stage: metadata
allow_failure: true
script:
- npmci command npm install -g tslint typescript
- npmci npm prepare
- npmci npm install
- npmci command "tslint -c tslint.json ./ts/**/*.ts"
tags:
- lossless
- docker
- priv
trigger:
stage: metadata
script:
- npmci trigger
only:
- tags
tags:
- lossless
- docker
- notpriv
pages:
stage: metadata
script:
- npmci node install lts
- npmci command npm install -g @gitzone/tsdoc
- npmci npm prepare
- npmci npm install
- npmci command tsdoc
tags:
- lossless
- docker
- notpriv
only:
- tags
artifacts:
expire_in: 1 week
paths:
- public
allow_failure: true

6
.idea/vcs.xml generated

@ -1,6 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="VcsDirectoryMappings">
<mapping directory="$PROJECT_DIR$" vcs="Git" />
</component>
</project>

@ -1,20 +0,0 @@
language: node_js
before_install:
- nvm install stable
- node -v
- npm -v
- npm install -g gulp
- npm install gulp
- npm install gulp-typescript
deploy:
provider: npm
email: npm@smart-coordination.com
api_key:
secure: P0Wz+4tHBh9+DeC92ZFB8U8M8PZSfv2nQpovc6dfVuDjQ62cbozbd8w49Qf3+/TQB6Duz9ZyOIg28c25/FoJ0UhqFuVqzhOS8pn5wv3E3+i2tZSFek2MIlHJLoy2hAOVi2jqhJ504+h/ncEU9J1z71cWiDWo7Bmb5R0J+0QfsHjH8Yz/b6WBgJOsneOxp8Ne+AWr5xq1Welx9Xh9AD99frWfQM3imX0/ticOW2fiUjiebuMNIzbGiE4Z6OAcgJFNU4Ny9n6xz4B0dHGXjmAHgzMdX4P1TEjEwbhXg9hDkobPn/BKJr+ora1sf/hk4AMSaVRiw3XcxrCy77bMMJB0TQYdiMfB+ZDQ4p6orDqbazvLgGE/vlG4mdv0Xp8kHX8gfkN8tGEluOFM2d1uxV+McKnau//ak61usuuk7D5O6uiDhKLE/zfBSw89h9UCC8MFmLQ2UUVdg90lH5MVhy5xDTEuZxvifCNIDGNtIVWQ0PM251ebma2F3RqL0pafTkydfcPb/ZkR6cjKr0fwG/s3HMChYB74MfAsX5GDFw9YY20jrcnVIPWBluRelTes+ajAakjTHPpk7ZkUSH/oJGV2TKDXI08xq3CYq7aULOl46fo2oz94r1tOuUHWynTKijLPqNu/P1IcmCMqRKlpBedNxVdT2enAliE3m6DP7LVsEV4=
on:
tags: true
repo: pushrocks/smarturl
notifications:
email: false
slack:
secure: f5Uss0z9RPl/QcA/DroB8loyE93aOYI6bqCkrsiUscmZtlv/TVQtT4dxqGA6uvcG6iTQDBi3Ul88dQxWkRm4IqbhY35/iMaV2dHW4FVYMAh8GQMbsfL2sALCcufxD9blw47awv3iFcwhV1EeyesscjgL0JIjduk96v/7G/6QIO2838M1lzlgtj+kRUkim8qkaEs1je3gRrhMUIjLuAdscMXyUKYFMjWo9ACSjVUl30R/ZNemb18itIja6i92GotreBgcfEMczvy58ovDC7xdJUsY8LjMI01DwY+WPRnI0tAhsuI8moBwwcdM4e3bAjKjucQRjO33O5bMWRZ6QCiYd0DnCEFyCPQLJ4GSy/tkD00n8ijLHAOSV3AH1zNbdK1EAdSPQXDvlI36KJn/2hyQLoitGHVUPr76ujJWP82ypO2tgIp3XQU0dJVCxDuHnwJO2+hjdI+gCPqxNTpjeujHx3UdkTGNRjuuf9dlZ/D08fApjYxy2fxItTqo3QjP/nrqvBXUOPP8yPHpjIT4H2t5Pr4SJjBGI6X4qhKyFj6s9rA/Xu1rL+45zu1C3uC3z+u3T9UwrbzJ/cZM6r6UQvQmUvIfBNaMlg4I/diQCDIPL+Rhop2nylY3IcHmJnk2itn7kOqj1tohCpFEml5pRuSZy4udWywkdtyBAsHWFLF7oiQ=

29
.vscode/launch.json vendored Normal file

@ -0,0 +1,29 @@
{
"version": "0.2.0",
"configurations": [
{
"name": "current file",
"type": "node",
"request": "launch",
"args": [
"${relativeFile}"
],
"runtimeArgs": ["-r", "@gitzone/tsrun"],
"cwd": "${workspaceRoot}",
"protocol": "inspector",
"internalConsoleOptions": "openOnSessionStart"
},
{
"name": "test.ts",
"type": "node",
"request": "launch",
"args": [
"test/test.ts"
],
"runtimeArgs": ["-r", "@gitzone/tsrun"],
"cwd": "${workspaceRoot}",
"protocol": "inspector",
"internalConsoleOptions": "openOnSessionStart"
}
]
}

26
.vscode/settings.json vendored Normal file

@ -0,0 +1,26 @@
{
"json.schemas": [
{
"fileMatch": ["/npmextra.json"],
"schema": {
"type": "object",
"properties": {
"npmci": {
"type": "object",
"description": "settings for npmci"
},
"gitzone": {
"type": "object",
"description": "settings for gitzone",
"properties": {
"projectType": {
"type": "string",
"enum": ["website", "element", "service", "npm"]
}
}
}
}
}
}
]
}

@ -1,12 +0,0 @@
# smarturl
offers smart ways to handle URLs
### Buildstatus/Dependencies
[![Build Status](https://travis-ci.org/pushrocks/gulp-bootstrap.svg?branch=master)](https://travis-ci.org/pushrocks/gulp-bootstrap)
[![devDependency Status](https://david-dm.org/pushrocks/gulp-bootstrap/dev-status.svg)](https://david-dm.org/pushrocks/gulp-bootstrap#info=devDependencies)
### Usage
TODO
Cheers
Phil from Lossless Digital

@ -1,6 +0,0 @@
/// <reference path="typings/tsd.d.ts" />
var path = require("path");
var openURL = require("open");
var smarturl = {};
smarturl.open = openURL;
module.exports = smarturl;

@ -1,6 +1,4 @@
The MIT License (MIT) Copyright (c) 2020 Lossless GmbH (hello@lossless.com)
Copyright (c) 2015 Push.Rocks
Permission is hereby granted, free of charge, to any person obtaining a copy Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal of this software and associated documentation files (the "Software"), to deal
@ -19,4 +17,3 @@ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE. SOFTWARE.

18
npmextra.json Normal file

@ -0,0 +1,18 @@
{
"gitzone": {
"projectType": "npm",
"module": {
"githost": "gitlab.com",
"gitscope": "pushrocks",
"gitrepo": "smarturl",
"shortDescription": "a url parsing lib",
"npmPackagename": "@pushrocks/smarturl",
"license": "MIT",
"projectDomain": "push.rocks"
}
},
"npmci": {
"npmGlobalTools": [],
"npmAccessLevel": "public"
}
}

1500
package-lock.json generated Normal file

File diff suppressed because it is too large Load Diff

@ -1,34 +1,36 @@
{ {
"name": "smarturl", "name": "@pushrocks/smarturl",
"version": "0.0.4", "version": "1.0.1",
"description": "offers smart ways to handle URLs", "private": false,
"main": "index.js", "description": "a url parsing lib",
"scripts": { "main": "dist_ts/index.js",
"test": "(cd ts/compile && gulp)", "typings": "dist_ts/index.d.ts",
"reinstall": "(rm -r node_modules && npm install)", "author": "Lossless GmbH",
"release": "(git pull origin master && npm version patch && git push origin master && git checkout release && git merge master && git push origin release && git checkout master)",
"startdev": "(git checkout master && git pull origin master)"
},
"repository": {
"type": "git",
"url": "https://github.com/pushrocks/smarturl.git"
},
"keywords": [
"json",
"jade",
"template"
],
"author": "Smart Coordination GmbH <office@push.rocks> (https://push.rocks)",
"license": "MIT", "license": "MIT",
"bugs": { "scripts": {
"url": "https://github.com/pushrocks/smarturl/issues" "test": "(tstest test/)",
}, "build": "(tsbuild)",
"homepage": "https://github.com/pushrocks/smarturl", "format": "(gitzone format)"
"dependencies": {
"open": "0.0.5"
}, },
"devDependencies": { "devDependencies": {
"gulp": "3.9.0", "@gitzone/tsbuild": "^2.0.22",
"gulp-typescript": "2.9.2" "@gitzone/tstest": "^1.0.15",
} "@pushrocks/tapbundle": "^3.0.7",
"@types/node": "^10.11.7",
"tslint": "^5.11.0",
"tslint-config-prettier": "^1.15.0"
},
"dependencies": {},
"files": [
"ts/**/*",
"ts_web/**/*",
"dist/**/*",
"dist_*/**/*",
"dist_ts/**/*",
"dist_ts_web/**/*",
"assets/**/*",
"cli.js",
"npmextra.json",
"readme.md"
]
} }

32
readme.md Normal file

@ -0,0 +1,32 @@
# @pushrocks/smarturl
a url parsing lib
## Availabililty and Links
* [npmjs.org (npm package)](https://www.npmjs.com/package/@pushrocks/smarturl)
* [gitlab.com (source)](https://gitlab.com/pushrocks/smarturl)
* [github.com (source mirror)](https://github.com/pushrocks/smarturl)
* [docs (typedoc)](https://pushrocks.gitlab.io/smarturl/)
## Status for master
[![pipeline status](https://gitlab.com/pushrocks/smarturl/badges/master/pipeline.svg)](https://gitlab.com/pushrocks/smarturl/commits/master)
[![coverage report](https://gitlab.com/pushrocks/smarturl/badges/master/coverage.svg)](https://gitlab.com/pushrocks/smarturl/commits/master)
[![npm downloads per month](https://img.shields.io/npm/dm/@pushrocks/smarturl.svg)](https://www.npmjs.com/package/@pushrocks/smarturl)
[![Known Vulnerabilities](https://snyk.io/test/npm/@pushrocks/smarturl/badge.svg)](https://snyk.io/test/npm/@pushrocks/smarturl)
[![TypeScript](https://img.shields.io/badge/TypeScript->=%203.x-blue.svg)](https://nodejs.org/dist/latest-v10.x/docs/api/)
[![node](https://img.shields.io/badge/node->=%2010.x.x-blue.svg)](https://nodejs.org/dist/latest-v10.x/docs/api/)
[![JavaScript Style Guide](https://img.shields.io/badge/code%20style-prettier-ff69b4.svg)](https://prettier.io/)
## Usage
Use TypeScript for best in class intellisense
## Contribution
We are always happy for code contributions. If you are not the code contributing type that is ok. Still, maintaining Open Source repositories takes considerable time and thought. If you like the quality of what we do and our modules are useful to you we would appreciate a little monthly contribution: You can [contribute one time](https://lossless.link/contribute-onetime) or [contribute monthly](https://lossless.link/contribute). :)
For further information read the linked docs at the top of this readme.
> MIT licensed | **&copy;** [Lossless GmbH](https://lossless.gmbh)
| By using this npm module you agree to our [privacy policy](https://lossless.gmbH/privacy)
[![repo-footer](https://lossless.gitlab.io/publicrelations/repofooter.svg)](https://maintainedby.lossless.com)

@ -1,3 +0,0 @@
/// <reference path="typings/tsd.d.ts" />
var smarturl = require("./index.js");
smarturl.open("https://mojo.io");

8
test/test.ts Normal file

@ -0,0 +1,8 @@
import { expect, tap } from '@pushrocks/tapbundle';
import * as smarturl from '../ts/index';
tap.test('first test', async () => {
console.log(smarturl.standardExport);
});
tap.start();

@ -1,2 +0,0 @@
nvm use v0.12.7
gulp

@ -1,25 +0,0 @@
// import gulp
var gulp = require("gulp"),
gulpTypescript = require("gulp-typescript");
gulp.task('compileTS', function() {
var stream = gulp.src('../index.ts')
.pipe(gulpTypescript({
out: "index.js"
}))
.pipe(gulp.dest("../../"));
return stream;
});
gulp.task('compileTestTS', function() {
var stream = gulp.src('../test.ts')
.pipe(gulpTypescript({
out: "test.js"
}))
.pipe(gulp.dest("../../"));
return stream;
});
gulp.task('default',['compileTS','compileTestTS'], function() {
console.log('Typescript compiled');
});

@ -1,2 +0,0 @@
# How to compile.
Make sure gulp and gulp-taypescript from npm are available. Then run the gulpfile in this directory.

@ -1,7 +0,0 @@
/// <reference path="typings/tsd.d.ts" />
var path = require("path");
var openURL = require("open");
var smarturl = {};
smarturl.open = openURL;
module.exports = smarturl;
//# sourceMappingURL=index.js.map

@ -1 +0,0 @@
{"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":"AAAA,yCAAyC;AACzC,IAAI,IAAI,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC;AAC3B,IAAI,OAAO,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC;AAE9B,IAAI,QAAQ,GAAO,EAAE,CAAC;AACtB,QAAQ,CAAC,IAAI,GAAG,OAAO,CAAC;AAIxB,MAAM,CAAC,OAAO,GAAG,QAAQ,CAAC"}

@ -1,10 +1,3 @@
/// <reference path="typings/tsd.d.ts" /> import * as plugins from './smarturl.plugins';
var path = require("path");
var openURL = require("open");
var smarturl:any = {}; export let standardExport = 'Hi there! :) This is an exported string';
smarturl.open = openURL;
module.exports = smarturl;

2
ts/smarturl.plugins.ts Normal file

@ -0,0 +1,2 @@
const removeme = {};
export { removeme };

@ -1,4 +0,0 @@
/// <reference path="typings/tsd.d.ts" />
var smarturl = require("./index.js");
smarturl.open("https://mojo.io");
//# sourceMappingURL=test.js.map

@ -1 +0,0 @@
{"version":3,"file":"test.js","sourceRoot":"","sources":["test.ts"],"names":[],"mappings":"AAAA,yCAAyC;AACzC,IAAI,QAAQ,GAAG,OAAO,CAAC,YAAY,CAAC,CAAC;AACrC,QAAQ,CAAC,IAAI,CAAC,iBAAiB,CAAC,CAAC"}

@ -1,3 +0,0 @@
/// <reference path="typings/tsd.d.ts" />
var smarturl = require("./index.js");
smarturl.open("https://mojo.io");

@ -1,12 +0,0 @@
{
"version": "v4",
"repo": "borisyankov/DefinitelyTyped",
"ref": "master",
"path": "typings",
"bundle": "typings/tsd.d.ts",
"installed": {
"node/node.d.ts": {
"commit": "efa0c1196d7280640e624ac1e7fa604502e7bd63"
}
}
}

File diff suppressed because it is too large Load Diff

1
ts/typings/tsd.d.ts vendored

@ -1 +0,0 @@
/// <reference path="node/node.d.ts" />

17
tslint.json Normal file

@ -0,0 +1,17 @@
{
"extends": ["tslint:latest", "tslint-config-prettier"],
"rules": {
"semicolon": [true, "always"],
"no-console": false,
"ordered-imports": false,
"object-literal-sort-keys": false,
"member-ordering": {
"options":{
"order": [
"static-method"
]
}
}
},
"defaultSeverity": "warning"
}