A mechanism for interacting with a computer operating system or software by typing commands to perform specific tasks.

learn more… | top users | synonyms (2)

8
votes
1answer
57 views

Ntree: a reimplementation of the tree utility

tree is described as "a recursive directory listing command that produces a depth indented listing of files" on the homepage for its Linux implementation. I don't ...
6
votes
2answers
104 views

Console colorizer

To be able to apply various colors to the console I created a ConosoleColorizer. It's really simple. It just takes an XML and renders it to the console with the ...
3
votes
1answer
38 views

X86 Legacy boot loader error trapping

The boot loader that I'm designing is just simply going to setup (A) Stack, (B) Segment registers (C) Load remainder of track for specified device. Conventionally, this could have been up to 4 floppy ...
3
votes
1answer
28 views

A telephone book command line program in ANSI C - follow-up 2

(See the previous iteration.) What does this program do? This program gives you a command line interface for managing your personal telephone book. The program supports three actions: Adding a ...
2
votes
1answer
42 views

Multi platform ASCII spinner in C

Okay I've just finished writing a nice tiny C program to have an ASCII spinner (works on Windows and POSIX). I'm quite new to C, so any suggestions would be great. This is designed to be a small ...
5
votes
2answers
35 views

Image batch processing in Ruby

I know a lot about Java, PHP and stuff, but I'm fairly new to ruby. I've written this script to look into the current working directory, get two parameters from the command line and then resize and ...
1
vote
1answer
41 views

A telephone book command line program in ANSI C - follow-up

(See the next iteration.) This question is a slight improvement over A telephone book command line program in ANSI C I have incorporated almost all points stated by Toby Speight. Now I have this: ...
2
votes
2answers
70 views

Simple library app

I'm trying to learn coding by actually coding my first working and hopefully expandable in future app. Yesterday I asked about optimizing my menu and got some answers about my take on it. Obviously ...
4
votes
1answer
65 views

A telephone book command line program in ANSI C

(See the next iteration.) Introduction I was in the mood for some C code and wrote this program for handling a personal telephone record book. One of the goals is strict portability; the code ...
1
vote
0answers
30 views

RSYNC Style Mirror Folder Application

I've written a mirror folder application in C#. It uses CommandLine for command line parsing. I'm just looking for a general review. ...
3
votes
3answers
109 views

Optimizing simple menu in console app

I want to optimize code in my simple app that I'm writing to learn C#. I feel it's really badly optimized in terms of good coding practises. Could anyone take a look at it and give me a hint to make ...
4
votes
1answer
92 views

Basic C# R-E-P-L

So I was thinking of making a C# REPL, as I didn't find any viable solution that would work for me, so I made a simple, basic one, I am sure it can be improved, as it seems once the REPL class is ...
0
votes
1answer
20 views

colorprint - part 2

This is a followup of the last review to comply with meta's rules. In the last, I posted a small library called colorprint and got some helpful pointers from chux ...
3
votes
1answer
23 views

colorprint - An ANSI Escape sequence console writer mini-library

I wrote this a long time ago. I came back to it and decided to clean it up a little. It uses the preprocessor and C99 anon structs to make a flexible python-like ...
2
votes
1answer
47 views

Multi threaded console IO

For many console applications it is handy to be able to receive input and output at the same time from multiple threads. This is supposed to allow receiving input commands from multiple threads, while ...
3
votes
1answer
52 views

Bash manual page selection menu

I wrote the following script in the hopes of streamlining the finding and reading of multiple manual pages. Since I am always looking up different utilities' manual pages I thought this would a good ...
1
vote
1answer
18 views

Pausing script while waiting for Docker container and printing updates

I'm looking to improve it in brevity, readability, and simplicity. Basically, I'm just looking for a more elegant solution. What improvements can I make? ...
4
votes
2answers
95 views

Java CLI Program Commands

As I was creating a CLI program, I realized having a ton of switch/if-then statements was a messy way to process user input. So, I set up a way to dynamically create commands as I added modules (...
1
vote
2answers
56 views

Calculate fractions of positive, negative and zeros

Find the fractions for, all positive numbers, all negative numbers and zeros in a given set of integer array. I wrote the below program. If you see any improvements required, please feel free to ...
2
votes
1answer
67 views

Console argument parsing and output printing in c#

I have a console application, which uses Ndesk.Options to parse console arguments, request weather data and print them. I am looking primarily for code style suggestions. This is the code, which ...
2
votes
0answers
199 views

Console command parser for my custom Libgdx console (gamedev)

For a game I'm writing using LibGDX framework and Kotlin language, I've decided to make a dev console. This is a WIP line parser. Since there's already a decent amount of code written I've decided to ...
4
votes
1answer
388 views

Display a List<T> in Console

I was searching for a way to display a List<T> with n elements in a user friendly and easy to handle way within the console application. So I wrote this ...
0
votes
1answer
56 views
25
votes
4answers
3k views

Loading… animating dots in C

I've recently wanted to make a "Loading..." display in C where the dots print one at a time in order and then reset: Suprisingly, there isn't much on the internet for doing this well, so I figured I ...
10
votes
1answer
150 views

Autocompleting console input

Yesterday I stumbled upon a Stack Overflow question that asked if it was possible to implement Tab-triggered auto-completion in a console application. I thought that was an interesting idea, so I ...
3
votes
3answers
401 views

BMI calculator in Python

This is my first attempt at writing a programme: a BMI calculator written in Python. Please give me feedback on the programme overall, as well as how easy the code is to interpret and adapt. ...
-1
votes
2answers
93 views

Object-oriented console adventure

I have been messing around with practicing some c++ making a little console game, and I would like to receive some advice and tips on how to improve my code. Some of the code is not done, meaning ...
6
votes
1answer
173 views

Emails, emails everywhere

My job entails me to send a lot of emails. I'm really bad at typing so I decided to create a program to do it for me. I've created an email generation tool (originally posted here.) I've changed ...
6
votes
1answer
83 views

Coloured bash prompt including git status and previous exit code

I wanted to create a short, informational and colourful prompt. My prompt includes: Exit status of last command (if not 0) Distinctive changes when root rsync-...
3
votes
0answers
27 views

Get only intended input from user through the console

I finally worked out all of the bugs in this bit of code. I'm pretty proud of it and I wanted to give it to all of you so that you could have it if you wanted it for any console programs that you make....
4
votes
2answers
889 views

Minesweeper C++

This is my improvement of a minesweeper game I took from the internet, which I am quite proud of. Nevertheless I am willing to hear your opinions, suggestions, and comments. ...
10
votes
0answers
150 views

Using argparse module within cmd interface

I've created an application that uses a cmd interface. It has multiple levels, and the number of available commands and their complexity is growing. As such, I need to generalise argument parsing - of ...
0
votes
1answer
170 views

How to flatten multiple nested node readline questions?

Say I'm creating a simple CLI. I want to use native node readline module to take in some input from user at prompt. I thought of this : ...
3
votes
3answers
62 views

Console Worker Follow-Up

A few hours ago I posted a similar question but this is a follow-up, I have revised the code and added and removed certain lines of code and hopefully improved it a bit, I just brought it here for a ...
2
votes
2answers
47 views

ConsoleWorker update console timer with how long application has been open

earlier I coded a quick console worker that runs a timer every 1 second and updates the consoles timer with how long the app has been open, how can I improve this? ...
5
votes
3answers
134 views

Console RPG - show cycle optimization

I have this RPG game and this has elements such as the map, the monsters and the items. The monsters and the items are stored in Lists and every time I want to show ...
3
votes
1answer
102 views

Connect Four in Java for two human players

Connect Four kinda caught my eye, and I decided to start from the very basics. Here I have bare-bones implementation for playing the game between two human players on the command line: Board.java <...
1
vote
2answers
39 views

Countdown Timer for Tests

I created this countdown timer as a tool to count down the remaining time on a test a few months ago. However, I looked at the code today and it looks like it needs some improvement, but I'm not sure ...
4
votes
2answers
104 views
2
votes
1answer
218 views

Moving files while preserving the folder structure

I'm writing a console application that will look through a directory and move any log files that have a date modified older than X days (configurable in the ...
7
votes
1answer
252 views

Basic C# calculator code

I have not had any experience with coding before, and after beginning to learn I stated working on this calculator which runs different functions on the console. I'd like to hopefully be taught what I ...
2
votes
2answers
112 views

Simple TicTacToe game in C++

I just started learning C++, and this is one of my projects. It's just a simple 2-player (No AI) TicTacToe game that runs from the console. The project was to familiarize myself with arrays, so review ...
4
votes
1answer
226 views

Getting keyboard input for real-time console application

I've been building an IDE using C# and only the console. To get keyboard input in real time (as opposed to a read–eval–print loop,) I have the following method to get keyboard input: ...
4
votes
1answer
156 views

Minimize the console window to tray

I have a small console application that runs a very long task and I would like to hide the console window when I click on the minimize button but keep a notify icon in the system tray so that I would ...
9
votes
3answers
566 views

First C# program (Snake game)

I've just started out using C#. I've used Scratch (drag and drop programming for kids) for quite some time. Since Scratch didn't have classes and methods I have a feeling this code could be a lot more ...
3
votes
0answers
29 views

Write to terminal and buffer

...
2
votes
1answer
111 views

C++ Console variables

I've written some code for console variables. They support different types e.g. integer, string, vector, float, etc. Is there a better way to do this? Like with an interface and a class for each ...
3
votes
1answer
29 views

Displaying a table of shell aliases

I'm just getting into bash and sh scripting. I mostly just stub out little convenience or exercise scripts for myself, but I recognize I may be flaunting best practices at times. My question is ...
6
votes
2answers
740 views

First program: a simple calculator

I'm reading this very good book, C# Player's Guide, to learn C#. I then plan to make video games with Unity 3D after. In one of the chapters, he asks us to make a (really) simple calculator as a ...
2
votes
2answers
132 views

png2jpeg, a utility for converting PNG to JPEG (rev. 2/3)

Revisions: Revision 1 Revision 2 (you are here) Revision 3 png2jpeg is a simple command-line converter of PNG to JPEG. The source code requires the libpng and libjpeg development libraries to be ...