All files can be found on the Releases page.
This Windows command line utility returns the current user's user name with a few case options (lower, upper, and title).
I wanted a way to get a user's name in any console/program environment without always depending on an environment's variable. I also wanted a way to programmatically change the case of the string.
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. There are both x86 (32 bit) and x64 (64 bit) versions of the executable.
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 (username
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[1], but if not then you have provide the full path (C:\Path\To\username.exe
for example) when executing the program.
Help message.
PS> username /?
User Name - Get the current user's user name with
case options.
username [/? | /h | /help] | [/l | /lower] | [/u | /upper]
[/t | /title]
/?, /h, /help This help screen.
/l, /lower Output is in lower case.
/u, /upper Output is in upper case.
/t, /title Output is in title case.
Get user's name normal.
PS> username
flux
Get user's name lower case.
PS> username /l
flux
Get user's name upper case.
PS> username /u
FLUX
Get user's name title case.
PS> username /t
Flux
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 |
Adding a path to the Windows %PATH% environment variable @ DuckDuckGo
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.