- Con Info (Windows version)
All files can be found on the Releases page.
This is a command line utility that can print some basic information about a console's (terminal display) size and the cursor position within that console.
This is a very basic version and does not work well for things like variables or file output. This is simply for your own use in profile configs and in-time/on-screen information. I do plan to write a more thorough version at some point.
This is the Windows version, but I have plans to write a Linux version[1] as well.
All executable binaries (portable and installation) provided by this repository were built at this repository and MD5 hashes were obtained during compile/build time and are updated at the same time and provided below and on the Release page.
I wrote this for use in the command line and especially for use in AutoHotkey[2] to help me get this sort of information so I can manipulate/control my console's better.
Yes, I know there are other ways to get this information, but I like to create my own tools just for the sake of it and because I know exactly what my program is doing.
If you like any of the projects below and care to donate to my PayPal:
Or Buy Me A Coffee if your prefer:
This is a Windows command line tool for CMD and PowerShell. This tool is a single stand-alone executable and therefore can be used portably, but has an installer provided. The installer provides a means for easy removal and the option to add the programs path to the %PATH%
environment variable (which is also removed on uninstallation). There are both x86 (32 bit) and x64 (64 bit) versions of both the portable and installer executables.
As with any portable program this can be placed anywhere you like on your machine, but more preferably in a directory that is in your %PATH%
environment variable so you can run it without a full path (coninfo
for example). I recommend using a dedicated Bin directory, but of course, it's your choice. If your path isn't already in your %PATH%
environment then I suggest adding it[3], but if not then you have provide the full path (C:\Path\To\coninfo.exe
for example) when executing the program.
Though it's not necessary an installer is provided for both the 32 bit and 64 bit versions. The installer provides a way to easily uninstall the program like you would any other Windows program and also provides the ability to automatically add the program's directory to the %PATH% environment variable. Everything is removed upon uninstallation. Just download the installer of your choice and run like you would any other intaller in Windows.
A preview is provided below.
PS> & coninfo /?
Con Info - Get a console's column and row size, cursor position, and buffer
size. Defaults to all information.
confinfo [/? | /h | /help] | [/b | /buffer] [/s | /size] [/C | /cursor]
[/c | /columns] [/r | /rows] [/bc | /buffercolumns]
[/br | /bufferrows] [/cc | /cursorcolumn] [/cr | /cursorrow]
[/u | /unformatted]
/?, /h, /help This help screen.
/b, /buffer Only print the buffer size by columns and rows.
/s, /size Only print the visible console's size by columns and
rows.
/C, /cursor Only print the cursor position by column and row.
/c, /columns Only print the visible console's column width.
/r, /rows Only print the visible console's column height.
/bc, /buffercolumns Only print the buffer's width.
/br, /bufferrows Only print the buffer's height.
/cc, /cursorcolumn Only print the cursors's column position (X).
/cr, /cursorrow Only print the cursors's row position (Y).
/u, /unformatted No special formatting; no color and only returns
integer values. Values are printed in their normal
formatted order. Implies /monochrome.
/m, /monochrome No color output.
PS>
PS> & coninfo
Console Information
Buffer Columns : [110]
Buffer Rows : [28]
Cursor Column : [0]
Cursor Row : [2]
Columns : [110]
Rows : [28]
PS>
PS> & coninfo /size
Console Information
Columns : [110]
Rows : [28]
PS>
PS> & coninfo /buffer
Console Information
Buffer Columns : [110]
Buffer Rows : [28]
PS>
The x and y coodinates of the cursor position of where the command executed.
PS> & coninfo /cursor
Console Information
Cursor Column : [0]
Cursor Row : [2]
PS>
PS> & coninfo /unformatted
110
28
0
2
110
28
PS>
This project is written in C++
.
This is graded by CodeFactor and is subjective, but helps me to refactor my work.
Name | Status |
---|---|
codefactor.io |
All hashes are retrieved at compile/build time.
Description | Status |
---|---|
Project Release Date | |
Total downloads for this project | |
Complete repository size | |
Commits in last month | |
Commits in last year |
I normally combine all architecture/operating system versions into one repository/project, but I'll be separating this into the different operating system's own repositories. The Android (Termux) version will be under Linux.
AutoHotkey is a powerful and fun (in my humble opinion) Windows scripting language which can be used to automate countless tasks in the Windows operating system from controlling hotkeys and hotstrings to creating full Win32 guis and making library function calls from DLLs.
Tips (from DuckDuckGo) for adding directory entries to the %PATH%
environment variable in Windows:
I created this.
License Excerpt
This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.