Skip to content

Surajkumar88/Oneliner

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Oneliner

logo

Packaging status

Index

Documents

Description

A command-line tool to convert multi-line bash script into a single-line command.

Features

  • Lightweight and simple tool to use in the command line🛠️.
  • Output can be shown in CLI, copied to a clipboard, or saved to file📥.
  • Formatting can be preserved in the output📋.

Dependencies

Use bash (v3.2 or later), script functionality might break with earlier versions.

GNU awk

installation

Manual installation

Clone and install

git clone https://github.com/Surajkumar88/Oneliner
cd Oneliner/src
make install

To install in a custom directory

make DESTDIR=path/to/directory install

NOTE: You may have to run this as root.

To uninstall

cd Oneliner/src
make uninstall

Usage

git [-f | --file <file_path>] [-options <value>]

Options

Options         Expected Value      Description
-f, --file      source path         path to the source file with the code to convert
-o, --output    file path           save the output to file oneliner_out.txt in the given path (defaults to current working directory)
-p, --print     on/off              verbose output in CLI
-m, --multiline on/off              output/copy file contents with source formatting 
-c, --copy      on/off              copy the output in clipboard 
-h, --help                          display this help and exit
-v, --version                       show version for Oneliner

TODO

Oneliner TODO

License

MIT License