Compare commits

...

26 Commits

Author SHA1 Message Date
ab5f8bf470 3.0.9 2020-02-20 22:13:15 +00:00
968219384d fix(core): update 2020-02-20 22:13:14 +00:00
dd5ca4b3f1 3.0.8 2020-02-20 22:06:38 +00:00
3c99bfe922 fix(core): update 2020-02-20 22:06:37 +00:00
4f62bfb622 3.0.7 2020-02-15 16:28:47 +00:00
5f00526a7c fix(core): update 2020-02-15 16:28:46 +00:00
0c1b9b3345 3.0.6 2020-02-15 15:17:47 +00:00
b32d64e5f2 fix(core): update 2020-02-15 15:17:46 +00:00
8342460c65 3.0.5 2020-02-15 15:16:52 +00:00
363142392b fix(core): update 2020-02-15 15:16:51 +00:00
390ee5edb7 3.0.4 2020-02-09 16:38:23 +00:00
35341c49ab fix(core): update 2020-02-09 16:38:22 +00:00
ba42658ee9 3.0.3 2020-01-19 10:20:40 +00:00
68687c2bca fix(core): update 2020-01-19 10:20:39 +00:00
2b76f54408 3.0.2 2020-01-19 10:20:19 +00:00
64561ab878 fix(core): update 2020-01-19 10:20:19 +00:00
8bb8574da7 3.0.1 2020-01-19 10:19:39 +00:00
6a5ecfcb19 fix(core): update 2020-01-19 10:19:38 +00:00
9a1c79c5de 3.0.0 2020-01-19 09:57:18 +00:00
1da9d73e5a BREAKING CHANGE(removed direct links in favour of directory style api): update 2020-01-19 09:57:17 +00:00
75173b1b37 2.0.13 2019-11-03 01:21:38 +01:00
e826047b9c fix(core): update 2019-11-03 01:21:38 +01:00
dd39b5d2ce 2.0.12 2019-10-21 17:29:11 +02:00
ab24929c6c fix(core): update 2019-10-21 17:29:10 +02:00
5da0b73a9d 2.0.11 2019-10-02 11:30:22 +02:00
73e10fc59b fix(core): update 2019-10-02 11:30:21 +02:00
22 changed files with 167 additions and 118 deletions

View File

@ -3,14 +3,14 @@ image: registry.gitlab.com/hosttoday/ht-docker-node:npmci
cache:
paths:
- .npmci_cache/
key: "$CI_BUILD_STAGE"
- .npmci_cache/
key: '$CI_BUILD_STAGE'
stages:
- security
- test
- release
- metadata
- security
- test
- release
- metadata
# ====================
# security stage
@ -18,21 +18,23 @@ stages:
mirror:
stage: security
script:
- npmci git mirror
- npmci git mirror
tags:
- docker
- notpriv
- lossless
- docker
- notpriv
snyk:
image: registry.gitlab.com/hosttoday/ht-docker-node:snyk
stage: security
script:
- npmci npm prepare
- npmci command npm install -g snyk
- npmci command npm install --ignore-scripts
- npmci command snyk test
tags:
- docker
- notpriv
- lossless
- docker
- notpriv
# ====================
# test stage
@ -41,37 +43,40 @@ snyk:
testStable:
stage: test
script:
- npmci npm prepare
- npmci node install stable
- npmci npm install
- npmci npm test
- npmci npm prepare
- npmci node install stable
- npmci npm install
- npmci npm test
coverage: /\d+.?\d+?\%\s*coverage/
tags:
- docker
- priv
- lossless
- docker
- priv
testBuild:
stage: test
script:
- npmci npm prepare
- npmci node install stable
- npmci npm install
- npmci command npm run build
- npmci npm prepare
- npmci node install stable
- npmci npm install
- npmci command npm run build
coverage: /\d+.?\d+?\%\s*coverage/
tags:
- docker
- notpriv
- lossless
- docker
- notpriv
release:
stage: release
script:
- npmci node install stable
- npmci npm publish
- npmci node install stable
- npmci npm publish
only:
- tags
- tags
tags:
- docker
- notpriv
- lossless
- docker
- notpriv
# ====================
# metadata stage
@ -85,30 +90,31 @@ codequality:
- npmci npm install
- npmci command "tslint -c tslint.json ./ts/**/*.ts"
tags:
- docker
- priv
- lossless
- docker
- priv
trigger:
stage: metadata
script:
- npmci trigger
- npmci trigger
only:
- tags
- tags
tags:
- docker
- notpriv
- lossless
- docker
- notpriv
pages:
image: hosttoday/ht-docker-dbase:npmci
services:
- docker:stable-dind
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:
@ -116,5 +122,5 @@ pages:
artifacts:
expire_in: 1 week
paths:
- public
- public
allow_failure: true

View File

66
package-lock.json generated
View File

@ -1,6 +1,6 @@
{
"name": "@tsclass/tsclass",
"version": "2.0.10",
"version": "3.0.9",
"lockfileVersion": 1,
"requires": true,
"dependencies": {
@ -914,9 +914,9 @@
}
},
"@gitzone/tstest": {
"version": "1.0.26",
"resolved": "https://verdaccio.lossless.one/@gitzone%2ftstest/-/tstest-1.0.26.tgz",
"integrity": "sha512-hmP62mwtRmFRAIjS/N3Vf1paZ6hN9lCJQm3J/6IFPk1UySJgJn0DLIlyWLvaNkq+WOOyT+q3EcVXWE1HV0WpsA==",
"version": "1.0.27",
"resolved": "https://verdaccio.lossless.one/@gitzone%2ftstest/-/tstest-1.0.27.tgz",
"integrity": "sha512-EX2mu03pUiKKkx8oKnOP7qvf1Hd1zE06lYge5CwoUFbrP2re8HW9eK+yuti+S+eynmXyzRsw34uTxxA4e9G3ZQ==",
"dev": true,
"requires": {
"@gitzone/tsbundle": "^1.0.40",
@ -1540,9 +1540,9 @@
"dev": true
},
"builtin-modules": {
"version": "1.1.1",
"resolved": "https://verdaccio.lossless.one/builtin-modules/-/builtin-modules-1.1.1.tgz",
"integrity": "sha1-Jw8HbFpywC9bZaR9+Uxf46J4iS8=",
"version": "3.1.0",
"resolved": "https://verdaccio.lossless.one/builtin-modules/-/builtin-modules-3.1.0.tgz",
"integrity": "sha512-k0KL0aWZuBt2lrxrcASWDfwOLMnodeQjodT/1SxEQAXsHANgo6ZC/VEaSEHCXt7aSTZ4/4H5LKa+tBXmW7Vtvw==",
"dev": true
},
"camel-case": {
@ -1704,9 +1704,9 @@
}
},
"commander": {
"version": "2.20.0",
"resolved": "https://verdaccio.lossless.one/commander/-/commander-2.20.0.tgz",
"integrity": "sha512-7j2y+40w61zy6YC2iRNpUe/NwhNyoXrYpHMrSunaMG64nRnaf96zO/KMQR4OyN/UnE5KLyEBnKHd4aG3rskjpQ==",
"version": "2.20.1",
"resolved": "https://verdaccio.lossless.one/commander/-/commander-2.20.1.tgz",
"integrity": "sha512-cCuLsMhJeWQ/ZpsFTbE765kvVfoeSddc4nU3up4fV+fDBcfUXnbITJ+JzhkdjzOqhURjZgujxaioam4RM9yGUg==",
"dev": true
},
"concat-map": {
@ -2190,14 +2190,6 @@
"dev": true,
"requires": {
"minimist": "^1.2.0"
},
"dependencies": {
"minimist": {
"version": "1.2.0",
"resolved": "https://verdaccio.lossless.one/minimist/-/minimist-1.2.0.tgz",
"integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=",
"dev": true
}
}
},
"jsonfile": {
@ -2342,9 +2334,9 @@
}
},
"minimist": {
"version": "0.0.8",
"resolved": "https://verdaccio.lossless.one/minimist/-/minimist-0.0.8.tgz",
"integrity": "sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0=",
"version": "1.2.0",
"resolved": "https://verdaccio.lossless.one/minimist/-/minimist-1.2.0.tgz",
"integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=",
"dev": true
},
"mkdirp": {
@ -2354,6 +2346,14 @@
"dev": true,
"requires": {
"minimist": "0.0.8"
},
"dependencies": {
"minimist": {
"version": "0.0.8",
"resolved": "https://verdaccio.lossless.one/minimist/-/minimist-0.0.8.tgz",
"integrity": "sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0=",
"dev": true
}
}
},
"moment": {
@ -2792,14 +2792,6 @@
"is-module": "^1.0.0",
"resolve": "^1.11.1",
"rollup-pluginutils": "^2.8.1"
},
"dependencies": {
"builtin-modules": {
"version": "3.1.0",
"resolved": "https://verdaccio.lossless.one/builtin-modules/-/builtin-modules-3.1.0.tgz",
"integrity": "sha512-k0KL0aWZuBt2lrxrcASWDfwOLMnodeQjodT/1SxEQAXsHANgo6ZC/VEaSEHCXt7aSTZ4/4H5LKa+tBXmW7Vtvw==",
"dev": true
}
}
},
"rollup-plugin-sourcemaps": {
@ -3114,16 +3106,16 @@
"dev": true
},
"tslint": {
"version": "5.19.0",
"resolved": "https://verdaccio.lossless.one/tslint/-/tslint-5.19.0.tgz",
"integrity": "sha512-1LwwtBxfRJZnUvoS9c0uj8XQtAnyhWr9KlNvDIdB+oXyT+VpsOAaEhEgKi1HrZ8rq0ki/AAnbGSv4KM6/AfVZw==",
"version": "5.20.0",
"resolved": "https://verdaccio.lossless.one/tslint/-/tslint-5.20.0.tgz",
"integrity": "sha512-2vqIvkMHbnx8acMogAERQ/IuINOq6DFqgF8/VDvhEkBqQh/x6SP0Y+OHnKth9/ZcHQSroOZwUQSN18v8KKF0/g==",
"dev": true,
"requires": {
"@babel/code-frame": "^7.0.0",
"builtin-modules": "^1.1.1",
"chalk": "^2.3.0",
"commander": "^2.12.1",
"diff": "^3.2.0",
"diff": "^4.0.1",
"glob": "^7.1.1",
"js-yaml": "^3.13.1",
"minimatch": "^3.0.4",
@ -3134,10 +3126,10 @@
"tsutils": "^2.29.0"
},
"dependencies": {
"diff": {
"version": "3.5.0",
"resolved": "https://verdaccio.lossless.one/diff/-/diff-3.5.0.tgz",
"integrity": "sha512-A46qtFgd+g7pDZinpnwiRJtxbC1hpgf0uzP3iG89scHk0AUC7A1TGxf5OiiOUv/JMZR8GOt8hL900hV0bOy5xA==",
"builtin-modules": {
"version": "1.1.1",
"resolved": "https://verdaccio.lossless.one/builtin-modules/-/builtin-modules-1.1.1.tgz",
"integrity": "sha1-Jw8HbFpywC9bZaR9+Uxf46J4iS8=",
"dev": true
}
}

View File

@ -1,6 +1,6 @@
{
"name": "@tsclass/tsclass",
"version": "2.0.10",
"version": "3.0.9",
"private": false,
"description": "common classes for TypeScript",
"main": "dist/index.js",
@ -29,17 +29,17 @@
"devDependencies": {
"@gitzone/tsbuild": "^2.1.17",
"@gitzone/tsrun": "^1.2.8",
"@gitzone/tstest": "^1.0.26",
"tslint": "^5.19.0",
"@gitzone/tstest": "^1.0.27",
"tslint": "^5.20.0",
"tslint-config-prettier": "^1.18.0"
},
"files": [
"ts/*",
"ts_web/*",
"dist/*",
"dist_web/*",
"dist_ts_web/*",
"assets/*",
"ts/**/*",
"ts_web/**/*",
"dist/**/*",
"dist_web/**/*",
"dist_ts_web/**/*",
"assets/**/*",
"cli.js",
"npmextra.json",
"readme.md"

View File

@ -49,6 +49,11 @@ class myOwnInvoice implements IInvoice {
> The modules in bold letters exist as own modules and can be used seperately
## 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 | **©** [Lossless GmbH](https://lossless.gmbh)

View File

@ -3,7 +3,7 @@ import { tap, expect } from '@pushrocks/tapbundle';
import * as tsclass from '../ts/index';
tap.test('should assign a correct type', async () => {
let contact: tsclass.IContact;
let contact: tsclass.business.IContact;
});
tap.start();

View File

@ -1,5 +1,4 @@
import { IContact } from '..';
import { IDate } from '..';
import { business, general } from '..';
/**
* describes a company's lifecycle state
@ -11,8 +10,8 @@ export type TCompanyStatus = 'planed' | 'founding' | 'active' | 'liquidation' |
*/
export interface ICompany {
name: string;
foundedDate: IDate;
closedDate: IDate;
status: TCompanyStatus;
contact: IContact;
foundedDate: general.IDate;
closedDate: general.IDate;
status: business.TCompanyStatus;
contact: business.IContact;
}

View File

@ -1,4 +1,4 @@
import { IAddress } from '..';
import { business } from '..';
export type TContactSalutation = 'Mr' | 'Ms' | 'Mrs';
@ -16,7 +16,7 @@ export interface IContact {
name: string;
surname?: string;
legalEntity?: string;
address: IAddress;
address: business.IAddress;
description: string;
customerNumber?: string;

View File

@ -0,0 +1,5 @@
export interface IContainer {
registryUrl: string;
tag: string;
version: string;
}

1
ts/container/index.ts Normal file
View File

@ -0,0 +1 @@
export * from './container';

View File

@ -1,4 +1,4 @@
import { IAuthor } from '..';
import { content } from '..';
export interface IArticle {
/**
@ -9,7 +9,7 @@ export interface IArticle {
/**
* the Author of an article
*/
author: IAuthor;
author: content.IAuthor;
/**
* the content of an article

View File

@ -1,5 +1,4 @@
import { IDate } from '..';
import { IArticle } from '..';
import { general, content } from '..';
export interface IAuthor {
/**
@ -15,10 +14,10 @@ export interface IAuthor {
/**
* the birthday of an author
*/
birthday: IDate;
birthday: general.IDate;
/**
* articles of an author
*/
articles: IArticle[];
articles: content.IArticle[];
}

View File

@ -1,8 +1,7 @@
import { TCurrency } from './currency';
import { ITransaction } from './transaction';
import { finance } from '../';
export interface ICheckingAccount {
name: string;
currency: TCurrency;
transactions: ITransaction[];
currency: finance.TCurrency;
transactions: finance.ITransaction[];
}

View File

@ -1,5 +1,4 @@
import { IInvoice } from './invoice';
import { IContact } from '../business/contact';
import { business } from '../';
export interface IExpenseItem {
description: string;
@ -14,5 +13,5 @@ export interface IVoucher {
date: Date;
description: string;
expenseItems: IExpenseItem[];
contactRef: IContact;
contactRef: business.IContact;
}

View File

@ -1,4 +1,4 @@
import { IContact } from '..';
import { business } from '..';
export type TInvoiceStatus = 'draft' | 'invoice' | 'paid' | 'refunded';
@ -10,8 +10,8 @@ export interface IInvoiceItem {
}
export interface IInvoice {
billedBy: IContact;
billedTo: IContact;
billedBy: business.IContact;
billedTo: business.IContact;
status: TInvoiceStatus;
items: IInvoiceItem[];
}

View File

@ -1,21 +1,19 @@
// Business
import * as business from './business';
export * from './business';
// Container
import * as container from './container';
// Finance
import * as finance from './finance';
export * from './finance';
// Content
import * as content from './content';
export * from './content';
// General
import * as general from './general';
export * from './general';
// Network
import * as network from './network';
export * from './network';
export { business, finance, content, general, network };
export { business, container, finance, content, general, network };

9
ts/network/cert.ts Normal file
View File

@ -0,0 +1,9 @@
export interface ICert {
id: string;
domainName: string;
created: number;
validUntil: number;
privateKey: string;
publicKey: string;
csr: string;
}

View File

@ -1 +1,20 @@
export type TDnsRecord = 'A' | 'AAAA' | 'CNAME' | 'TXT' | 'SRV' | 'LOC' | 'MX' | 'NS' | 'SPF';
export type TDnsRecordType =
| 'A'
| 'AAAA'
| 'CNAME'
| 'LOC'
| 'PTR'
| 'MX'
| 'NAPTR'
| 'NS'
| 'SOA'
| 'SPF'
| 'SRV'
| 'TXT';
export interface IDnsRecord {
name: string;
type: TDnsRecordType;
value: string;
dnsSecEnabled: boolean;
}

View File

@ -0,0 +1,4 @@
export interface IDnsChallenge {
hostName: string;
challenge: string;
}

View File

@ -1,2 +1,5 @@
export * from './reverseproxy';
export * from './cert';
export * from './dns';
export * from './dnschallenge';
export * from './networknode';
export * from './reverseproxy';

View File

@ -0,0 +1,6 @@
export interface INetworkNode {
name: string;
ipv4: string;
ipv6: string;
securityLevel: 'private' | 'public' | 'confidential';
}

View File

@ -4,4 +4,9 @@ export interface IReverseProxyConfig {
hostName: string;
privateKey: string;
publicKey: string;
authentication?: {
type: 'Basic';
user: string;
pass: string;
};
}