Mintshell Terminal

Terminal interfaces of Mintshell

License

License

Categories

Categories

MINA Net Networking
GroupId

GroupId

org.mintshell
ArtifactId

ArtifactId

mintshell-terminal
Last Version

Last Version

0.3.0
Release Date

Release Date

Type

Type

jar
Description

Description

Mintshell Terminal
Terminal interfaces of Mintshell
Project Organization

Project Organization

Mintshell

Download mintshell-terminal

How to add to project

<!-- https://jarcasting.com/artifacts/org.mintshell/mintshell-terminal/ -->
<dependency>
    <groupId>org.mintshell</groupId>
    <artifactId>mintshell-terminal</artifactId>
    <version>0.3.0</version>
</dependency>
// https://jarcasting.com/artifacts/org.mintshell/mintshell-terminal/
implementation 'org.mintshell:mintshell-terminal:0.3.0'
// https://jarcasting.com/artifacts/org.mintshell/mintshell-terminal/
implementation ("org.mintshell:mintshell-terminal:0.3.0")
'org.mintshell:mintshell-terminal:jar:0.3.0'
<dependency org="org.mintshell" name="mintshell-terminal" rev="0.3.0">
  <artifact name="mintshell-terminal" type="jar" />
</dependency>
@Grapes(
@Grab(group='org.mintshell', module='mintshell-terminal', version='0.3.0')
)
libraryDependencies += "org.mintshell" % "mintshell-terminal" % "0.3.0"
[org.mintshell/mintshell-terminal "0.3.0"]

Dependencies

compile (3)

Group / Artifact Type Version
org.mintshell : mintshell-api jar 0.3.0
org.mintshell : mintshell-core jar 0.3.0
org.slf4j : slf4j-api jar 1.7.25

test (2)

Group / Artifact Type Version
junit : junit jar 4.12
org.assertj : assertj-core jar 3.8.0

Project Modules

There are no modules declared in this project.

mintshell

Mintshell is a Java library which allows to provide Java applications with a comfortable, interactive command line shell in a very easy way. MINT stands for Multiple INTerface. This means, that commands can be provided by many different interfaces to control the (same) application. By default there are several kinds of interfaces available, including terminal-based interfaces (Console, SSH) and network-based interfaces (REST/HTTP). Because of mintshell's open architecture it's easily possible to extend or replace components - especially interfaces - with custom implementations.

Features

  • Easy to use builder pattern (one-liner)
  • Console interface (supporting single keys through native lib)
  • SSH interface (currently without security mechanisms)
  • Reflection dispatcher (for foreign classes)
  • Annotation support (for comfortable command configuration)

Note: mintshell requires Java 8

Roadmap

0.1.0 (first release, planned yet in 2017)

  • Grammar-based command interpreter
  • Command history in terminal-based command interfaces
  • Command help support
  • Native libs for OSX/Linux

0.2.0

  • Native libs for further Linux distributions
  • Native libs for Windows
  • Command pipe support
  • Subshells
  • Autocompletion

Overview

The basic concept consists of four main components which are arranged as kind of a pipeline:

CommandInterface -> CommandInterpreter -> CommandDispatcher -> CommandTarget

TODO: picture

Command Interface

The CommandInterface is a somehow natured technical interface, that is able to accept command lines. Usually command lines are strings consisting of a command and optionally one or more parameters. However, this is not a hard requirement, because the only important thing is that the used CommandInterpreter is able to understand the accepted kind of command line.

Command Interpreter

The CommandInterpreter is responsible to transform an accepted command line into a Command object, that is provided to the CommandDispatcher in order to be executed.

Command Dispatcher

The CommandDispatcher manages one ore more CommandTargets and is responsible to dispatch incoming Commands to the corresponding CommandTarget or in other words to execute a Command "upon" the CommandTarget.

Command Target

_CommandTarget_s are components that finally execute a Command. All preceeding components are only responsible to accept, transform and prepare a command line in such a way, that it becomes executable at the CommandTarget. Usually a CommandTarget is an arbitrary Java class or Java object, which methods are mapped to Commands and thereby are accessible for a user through the CommandInterface. However, this concept is also replacable by custom implementations.

About Commands

TODO

Further reading

  1. Getting started
  2. Command Interfaces
  3. Command Dispatchers

Versions

Version
0.3.0
0.2.0
0.1.0