scala-cli-tools

Scala Command-Line Interface Tools

License

License

Categories

Categories

Scala Languages CLI User Interface
GroupId

GroupId

com.github.wookietreiber
ArtifactId

ArtifactId

scala-cli-tools_2.11
Last Version

Last Version

0.3.1
Release Date

Release Date

Type

Type

jar
Description

Description

scala-cli-tools
Scala Command-Line Interface Tools
Project URL

Project URL

https://github.com/wookietreiber/scala-cli-tools
Project Organization

Project Organization

com.github.wookietreiber
Source Code Management

Source Code Management

https://github.com/wookietreiber/scala-cli-tools

Download scala-cli-tools_2.11

How to add to project

<!-- https://jarcasting.com/artifacts/com.github.wookietreiber/scala-cli-tools_2.11/ -->
<dependency>
    <groupId>com.github.wookietreiber</groupId>
    <artifactId>scala-cli-tools_2.11</artifactId>
    <version>0.3.1</version>
</dependency>
// https://jarcasting.com/artifacts/com.github.wookietreiber/scala-cli-tools_2.11/
implementation 'com.github.wookietreiber:scala-cli-tools_2.11:0.3.1'
// https://jarcasting.com/artifacts/com.github.wookietreiber/scala-cli-tools_2.11/
implementation ("com.github.wookietreiber:scala-cli-tools_2.11:0.3.1")
'com.github.wookietreiber:scala-cli-tools_2.11:jar:0.3.1'
<dependency org="com.github.wookietreiber" name="scala-cli-tools_2.11" rev="0.3.1">
  <artifact name="scala-cli-tools_2.11" type="jar" />
</dependency>
@Grapes(
@Grab(group='com.github.wookietreiber', module='scala-cli-tools_2.11', version='0.3.1')
)
libraryDependencies += "com.github.wookietreiber" % "scala-cli-tools_2.11" % "0.3.1"
[com.github.wookietreiber/scala-cli-tools_2.11 "0.3.1"]

Dependencies

compile (2)

Group / Artifact Type Version
org.scala-lang : scala-library jar 2.11.12
com.chuusai : shapeless_2.11 jar 2.3.3

test (1)

Group / Artifact Type Version
com.lihaoyi : utest_2.11 jar 0.6.4

Project Modules

There are no modules declared in this project.

Scala CLI Tools

Build Status Codacy Badge Scaladoc

A collection of Scala command-line interface tools.

Table of Contents

Library

Memory

Humanize or dehumanize bytes:

import scalax.cli.Memory

Memory.humanize(10485760) // "10 MiB"

implicit val MU = Memory.SI
Memory.dehumanize("10 MB") // Some(10000000)

Table

Print a pretty command line table:

// create the table builder object

import scalax.cli.Table
import shapeless.Sized

val table = Table(Sized("h1", "h2", "h3"))

table.rows += Sized("a", "b", "c")
table.rows += Sized("d", "e", "f")

table.alignments(1) = Table.Alignment.Right

// get lines

val lines: List[String] = table.lines

// print it directly

table.print()
table.print(Console.err)

// h1 | h2 | h3
// ---|----|---
// a  |  b | c
// d  |  e | f

Apps

  • dehumanize un-pretty-print byte values
  • highlight search for pattern and highlight matches
  • humanize pretty-print byte values
  • meansd print mean and standard deviation

Installation

Arch Linux

Install all apps with the scala-cli-tools AUR package:

pacaur -S scala-cli-tools

Manual

Install all apps to ~/bin:

PREFIX=$HOME NATIVE_MODE=release \
  sbt install

Versions

Version
0.3.1
0.2.0
0.1.0
0.0.1