Skip to content

Commit

Permalink
Updated the aliases to the root of the package, rather than directly …
Browse files Browse the repository at this point in the history
…to a subdir such as /interfaces or /enums
  • Loading branch information
KristofVDB1 committed Jan 18, 2024
1 parent c688bbc commit 69d3ded
Show file tree
Hide file tree
Showing 18 changed files with 31 additions and 21 deletions.
2 changes: 1 addition & 1 deletion packages/oslo-converter-stakeholders/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
"license": "MIT",
"main": "index.js",
"_moduleAliases": {
"../enums": "./lib/enums"
"@oslo-converter-stakeholders": "./lib"
},
"bin": {
"oslo-stakeholders-converter": "./bin/runner.js"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import type {
import { injectable } from 'inversify';
import { container } from './config/DependencyInjectionConfig';
import { EaUmlConverterServiceIdentifier } from './config/EaUmlConverterServiceIdentifier';
import type { IConnectorNormalisationCase } from '@interfaces/IConnectorNormalisationCase';
import type { IConnectorNormalisationCase } from '@oslo-converter-uml-ea/interfaces/IConnectorNormalisationCase';

@injectable()
export class ConnectorNormalisationService {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import type { DataRegistry, EaObject } from '@oslo-flanders/ea-uml-extractor';
import { container } from './config/DependencyInjectionConfig';
import { EaUmlConverterServiceIdentifier } from './config/EaUmlConverterServiceIdentifier';
import { UriRegistry } from './UriRegistry';
import type { ConverterHandler } from '@interfaces/ConverterHandler';
import type { ConverterHandler } from '@oslo-converter-uml-ea/interfaces/ConverterHandler';

export class ConverterHandlerService<T extends EaObject> {
public readonly logger: Logger;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ import { EaUmlConversionService } from '../EaUmlConversionService';
import { OutputHandlerService } from '../OutputHandlerService';
import { EaUmlConverterConfiguration } from './EaUmlConverterConfiguration';
import { EaUmlConverterServiceIdentifier } from './EaUmlConverterServiceIdentifier';
import type { ConverterHandler } from '@interfaces/ConverterHandler';
import type { ConverterHandler } from '@oslo-converter-uml-ea/interfaces/ConverterHandler';

export const container = new Container();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import { inject, injectable } from 'inversify';
import { EaUmlConverterServiceIdentifier } from '../config/EaUmlConverterServiceIdentifier';
import { TagNames } from '../enums/TagNames';
import { getTagValue, toCamelCase, toPascalCase } from '../utils/utils';
import type { IConnectorNormalisationCase } from '@interfaces/IConnectorNormalisationCase';
import type { IConnectorNormalisationCase } from '@oslo-converter-uml-ea/interfaces/IConnectorNormalisationCase';

@injectable()
export class AssociationWithAssociationClassConnectorCase implements IConnectorNormalisationCase {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import { inject, injectable } from 'inversify';
import { EaUmlConverterServiceIdentifier } from '../config/EaUmlConverterServiceIdentifier';
import { TagNames } from '../enums/TagNames';
import { getTagValue, toCamelCase, updateNameTag } from '../utils/utils';
import type { IConnectorNormalisationCase } from '@interfaces/IConnectorNormalisationCase';
import type { IConnectorNormalisationCase } from '@oslo-converter-uml-ea/interfaces/IConnectorNormalisationCase';

@injectable()
export class AssociationWithDestinationRoleConnectorCase implements IConnectorNormalisationCase {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import { inject, injectable } from 'inversify';
import { EaUmlConverterServiceIdentifier } from '../config/EaUmlConverterServiceIdentifier';
import { TagNames } from '../enums/TagNames';
import { getTagValue, toCamelCase, toPascalCase, updateNameTag } from '../utils/utils';
import type { IConnectorNormalisationCase } from '@interfaces/IConnectorNormalisationCase';
import type { IConnectorNormalisationCase } from '@oslo-converter-uml-ea/interfaces/IConnectorNormalisationCase';

@injectable()
export class AssociationWithNameConnectorCase implements IConnectorNormalisationCase {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import { inject, injectable } from 'inversify';
import { EaUmlConverterServiceIdentifier } from '../config/EaUmlConverterServiceIdentifier';
import { TagNames } from '../enums/TagNames';
import { getTagValue, toCamelCase, updateNameTag } from '../utils/utils';
import type { IConnectorNormalisationCase } from '@interfaces/IConnectorNormalisationCase';
import type { IConnectorNormalisationCase } from '@oslo-converter-uml-ea/interfaces/IConnectorNormalisationCase';

@injectable()
export class AssocationWithSourceRoleConnectorCase implements IConnectorNormalisationCase {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import { inject, injectable } from 'inversify';
import { EaUmlConverterServiceIdentifier } from '../config/EaUmlConverterServiceIdentifier';
import { TagNames } from '../enums/TagNames';
import { getTagValue, toCamelCase, toPascalCase } from '../utils/utils';
import type { IConnectorNormalisationCase } from '@interfaces/IConnectorNormalisationCase';
import type { IConnectorNormalisationCase } from '@oslo-converter-uml-ea/interfaces/IConnectorNormalisationCase';

@injectable()
export class SelfAssociationWithAssociationClassConnectorCase implements IConnectorNormalisationCase {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import {
toPascalCase,
updateNameTag,
} from '../utils/utils';
import type { IConnectorNormalisationCase } from '@interfaces/IConnectorNormalisationCase';
import type { IConnectorNormalisationCase } from '@oslo-converter-uml-ea/interfaces/IConnectorNormalisationCase';

@injectable()
export class SelfAssociationWithNameConnectorCase implements IConnectorNormalisationCase {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import { DataTypes, datatypeIdentifierToHash } from '../enums/DataTypes';
import { TagNames } from '../enums/TagNames';
import type { UriRegistry } from '../UriRegistry';
import { getTagValue, ignore, toCamelCase } from '../utils/utils';
import { ConverterHandler } from '@interfaces/ConverterHandler';
import { ConverterHandler } from '@oslo-converter-uml-ea/interfaces/ConverterHandler';

@injectable()
export class AttributeConverterHandler extends ConverterHandler<EaAttribute> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import { ConnectorNormalisationService } from '../ConnectorNormalisationService'
import { TagNames } from '../enums/TagNames';
import type { UriRegistry } from '../UriRegistry';
import { getTagValue, ignore } from '../utils/utils';
import { ConverterHandler } from '@interfaces/ConverterHandler';
import { ConverterHandler } from '@oslo-converter-uml-ea/interfaces/ConverterHandler';

@injectable()
export class ConnectorConverterHandler extends ConverterHandler<NormalizedConnector> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import { injectable } from 'inversify';
import { TagNames } from '../enums/TagNames';
import type { UriRegistry } from '../UriRegistry';
import { getTagValue, ignore, toPascalCase } from '../utils/utils';
import { ConverterHandler } from '@interfaces/ConverterHandler';
import { ConverterHandler } from '@oslo-converter-uml-ea/interfaces/ConverterHandler';

@injectable()
export class ElementConverterHandler extends ConverterHandler<EaElement> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import { injectable } from 'inversify';
import { TagNames } from '../enums/TagNames';
import type { UriRegistry } from '../UriRegistry';
import { getTagValue, ignore } from '../utils/utils';
import { ConverterHandler } from '@interfaces/ConverterHandler';
import { ConverterHandler } from '@oslo-converter-uml-ea/interfaces/ConverterHandler';

@injectable()
export class PackageConverterHandler extends ConverterHandler<EaPackage> {
Expand Down
2 changes: 1 addition & 1 deletion packages/oslo-converter-uml-ea/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
"license": "MIT",
"main": "index.js",
"_moduleAliases": {
"@interfaces": "./lib/interfaces"
"@oslo-converter-uml-ea": "./lib"
},
"bin": {
"oslo-converter-ea": "./bin/runner.js"
Expand Down
2 changes: 1 addition & 1 deletion packages/oslo-core/lib/logging/LogUtil.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import type { LoggerFactory } from './LoggerFactory';
import type { LogLevel } from './LogLevel';
import { VoidLoggerFactory } from './VoidLoggerFactory';
import { WinstonLoggerFactory } from './WinstonLoggerFactory';
import type { YargsParams } from '@interfaces/AppRunner';
import type { YargsParams } from '@oslo-core/interfaces/AppRunner';

let loggerFactory: LoggerFactory = new VoidLoggerFactory();

Expand Down
2 changes: 1 addition & 1 deletion packages/oslo-core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
"license": "MIT",
"main": "index.js",
"_moduleAliases": {
"@interfaces": "./lib/interfaces"
"@@oslo-core": "./lib"
},
"directories": {
"lib": "lib"
Expand Down
18 changes: 14 additions & 4 deletions tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,20 @@
"emitDecoratorMetadata": true,
"baseUrl": ".", // This must be specified if "paths" is.
"paths": {
"@interfaces/*": [
"packages/oslo-converter-stakeholders/lib/interfaces/*",
"packages/oslo-converter-uml-ea/lib/interfaces/*",
"packages/oslo-core/lib/interfaces/*",
"@oslo-converter-uml-ea/*": ["packages/oslo-converter-uml-ea/lib/*"],
"@oslo-core/*": ["packages/oslo-core/lib/*"],
"@oslo-extractor-uml-ea/*": ["packages/oslo-extractor-uml-ea/lib/*"],
"@oslo-converter-stakeholders/*": [
"packages/oslo-converter-stakeholders/lib/*"
],
"@oslo-generator-jsonld-context/*": [
"packages/oslo-generator-jsonld-context/lib/*"
],
"@oslo-generator-rdf-vocabulary/*": [
"packages/oslo-generator-rdf-vocabulary/lib/*"
],
"@oslo-generator-respec-html/*": [
"packages/oslo-generator-respec-html/lib/*"
]
}
},
Expand Down

0 comments on commit 69d3ded

Please sign in to comment.