d-dog is a simple command-line tool inspired by the UNIX cat
command, implemented in the D programming language.
$ dog <file>
For example, to display the content of poem.txt
$ dog poem.txt
Make sure you have dmd
and dub
installed on your system.
In case you don't have the tools installed, you can go to the official Dlang website and download the necessary installer for your system, or install it from the repositories of your distribution's package manager if you use Linux.
To verify that they are installed correctly and you have it on your system, type these commands depending on your system:
$ dmd --version
> dmd --version
$ dub --version
> dub --version
After you have verified that you have these tools installed, you can run:
$ dub build
$ sudo mv dog /usr/local/bin
By the way, if you want, you can also use doas
:
$ doas mv dog /usr/local/bin
If you want to run dog.exe
from any location on the command line, you can add the directory where dog.exe
is located to the system PATH. You can follow these steps:
- Right-click on
This Computer
(orMy Computer
) in File Explorer and selectProperties
. - In the System Properties window, click on
Advanced System Settings
. - In the System Properties window, go to the
Advanced
tab and click onEnvironment Variables
. - In the
System Variables
section, find the variable calledPath
and clickEdit
. - Click on
New
and add the path to the project directory. - Click
OK
in all windows to save the changes.
Your collaboration would be a great help and something I would appreciate, you are welcome to contribute. Of course, although it is obvious, you must know how to program in Dlang, and also DO NOT write malicious code.
This project is licensed under the MIT License - see the LICENSE file for details.