ergonomica

A Bash alternative written in Python.

Follow me on GitHub

Ergonomica

A Bash alternative written in Python.

Why use ergonomica?

Ergonomica is a Python-based console language, integrating modules such as os, shutil, and subprocess into a fast, easy-to use environment. It allows for functional programming tools and operations as well as data types that would otherwise require obscure grep or sed commands.

Examples

Mapping a function

[lschumm@/Users/lschumm]
$ ls -> (map) x + " is on my computer"
.emacs.d is on my computer
Applications is on my computer
Desktop is on my computer
Documents is on my computer
Library is on my computer
Movies is on my computer
Music is on my computer
Pictures is on my computer
Public is on my computer

Filtering

[lschumm@/Users/lschumm]
$ ls -> (filter) x[0] == "P"
Pictures
Public

Moving some log files into folders based on year

[lschumm@/Users/lschumm]
$ ls
2016-1.log
2016-2.log
2016-3.log
2015-1.log
2015-2.log
2015-3.log
2014-1.log
2014-2.log
2014-3.log
2013-1.log
2013-2.log
2013-3.log
$ ls -> (map) x[:4] ->  mkdir
$ ls -> (map) x[:4] -> (filter) "log" in x -> (splice) -> mv
$ ls
2016
2015
2014
2013

Authors

Liam Schumm (@lschumm), Lead Developer. Andy Merrill (@appleinventor14), Developer. Dhyan Patel (@dpp2000), Developer.

Support or Contact

Feel free to file issues at our github page.