Manuel Selva
Manuel Selva

Reputation: 19050

How write a simple command line tool in C?

I want to write in C a command line tool with the following requirements:

I am not asking for code here, but for indications about where to start. I first made some experiments with "scanf" and it quickly become quite complicated. I then looked at ncurses, and it seems also quite low level. Is there any C libraries dedicated to this task, where would you start ?

Upvotes: 0

Views: 715

Answers (2)

Manuel Selva
Manuel Selva

Reputation: 19050

The GNU Readline library is exactly designed for that.

Upvotes: 1

Gluttton
Gluttton

Reputation: 5988

I then looked at ncurses, and it seems also quite low level

CDK (Curses Development Kit) - high-level wrapper over ncurses. I've had successful experience with it. When you need you always can use ncurses directly.

Upvotes: 2

Related Questions