Base System: Readme

GitHub watchers GitHub stars GitHub forks

npm package latest version Gemnasium status GitHub issues

This is the base package for the alinex namespace. Currently only some helpers are contained here.

It is not made to be used for other modules. Currently it contains:

  • the app logo (for console)
  • error management

Read more about the philosphy behind.

Install

NPM Downloads

API Integration

To do this you install it into your own module:

Shell Script
# from within your module directory sudo npm install --save alinex-core

Usage

You can get an logo easily to be printed on the console with the application title included:

CoffeeScript Code
alinex = require 'alinex-core' logo = alinex.logo 'Development Helper' console.log logo

Error Management

The following code will setup handler for SIGNAL handling and also give you a handy method for exit the program with code and message.

CoffeeScript Code
alinex = require 'alinex-core' alinex.initExit() alinex.exit 1, new Error "Something went wrong"

This will:

  • output the error
  • output a possible err.description property
  • exit the process with the given code

You can find the possible codes for alinex in in the description of the Error Management.

See the separate pages for theAPI Usage for more details.

Alinex Modules

Look at my Code page (button on the top) to get a list of currently finished modules.

License

© Copyright 2016 Alexander Schilling

Licensed under the Apache License, Version 2.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at

https://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an “AS IS” BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.