Giter Site home page Giter Site logo

rinp's Introduction






welcome to a Simple, Beautiful, Modern CLI application
for running multi-commands in parallel.



usage

⚫ usage ⚪ screenshotexamplesgoalbottomtop


  1. git clone https://github.com/k-five/rinp
  2. cd rinp/src/
  3. make build

sample output after make build

build mode:
compile: main.c rinp.c... okay
linking: main.o rinp.o... okay
Now you can install it by: sudo cp rinp /usr/bin/
"sude" is for root privilege. Use your own.


screenshot

usage ⚫ screenshot ⚪ examplesgoalbottomtop


Here is a screen-shot of running 10 sleep commands simultaneously. One of them is failed and others are succeeded.




examples

usagescreenshot ⚫ examples ⚪ goalbottomtop


As a quick start, you can use echo -e command. -e is for handing special characters like newline (= '\n') and so on.

  • echo -e '1\ntwo\n3' | rinp -le sleep runs 3 sleep commands which 1 of them is failed and the other two are succeed.
  • echo -e '1\n\n\n\n | rinp -le sleep runs only one sleep command, because newlines are ignored when they are just empty lines.

If you liked to see behind the scene then try using watch command as follows:
watch -n 1 -exec ps --forest -g -p process-id-of-your-terminal
for watching all the children of your Terminal every 1 second. You will face something like this:



goal

usagescreenshotexamples ⚫ goal ⚪ bottomtop


This app is suitable for running muilt-lengthy commands that you do NOT want to see their outputs. I had a lot of .mp4 files that should be converted to .mp3. Of course I could use xargs with redirection (= &> /dev/null), but I also liked to see if the commands are failed or succeeded.
Plus practicing some advanced techniques in C and Linux Programming that I have learned and some tiny of UI/UX. I daily use it for:

ls *.mp4 | rinp -le ffmpeg -i {} {}.mp3

which converts mp4 files to .mp3s. Of course you can use it for cp or mv or anything you like. I also tried to add some comments to the code, so you can read it as an educational code.



license

usagescreenshotexamplesgoal ⚫ bottom ⚪ top

rinp copyright © 2017 Shakiba

▒█▀▀█ ▒█▀▀█ ▒█░░░ █▀▀█
▒█░▄▄ ▒█▄▄█ ▒█░░░ ░░▀▄
▒█▄▄█ ▒█░░░ ▒█▄▄█ █▄▄█

rinp's People

Contributors

moshirishakiba avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.