Skip to content

πŸ–₯ [Nim] [CLI] CLI tool that allows changing Zebra printers password. (nim)

License

Notifications You must be signed in to change notification settings

angelside/zebra-password-changer-cli-nim

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

27 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Zebra Password Changer CLI

maintenance-status Nim Linux Windows License

Zebra Password Changer CLI is a "blazingly fast 🀣" CLI tool that allows changing Zebra printer's web interface password with socket protocol. Written with Nim πŸ‘‘ programming language.

πŸ“¦ Installation

No installation, no dependencies, it's in binary format.

πŸš€ Compilation

⚠️ You must compile it yourself until any binary is released.

This cli tool is built with Nim programming language. For binary compilation, you need to install nim toolchain and you can use the below command inside the tool root directory. The custom compilation configurations in the config.nims file will be used. The command will create ./bin/zebra-password-changer binary file.

Default compilation

$ nim c ./src/main.nim

Custom binary file name sample

$ nim c -o:./bin/my-super-duper-cli-app ./src/main.nim

A full walkthrough can be like below

$ git clone https://github.com/angelside/zebra-password-changer-cli-nim.git
$ cd zebra-password-changer-cli-nim
$ nim c ./src/main.nim
$ ./bin/zebra-password-changer help

ℹ️ It's a single binary file, you can move the file anywhere and/or can add it to PATH.

πŸ”¨ Usage

CLI tool has two parameters: the printer's IP address and the new password (4 digits, only numbers). We don't have to know the current password.

$ ./bin/zebra-password-changer <IP_ADDRESS> <PASSWORD>

πŸ“‹ Sample usages and results

successful

$ ./bin/zebra-password-changer <IP_ADDRESS> <PASSWORD>
== Zebra password changer ==

[OK] 172.18.197.202 : password has been changed.

with errors

$ ./bin/zebra-password-changer <IP_ADDRESS> <PASSWORD>
== Zebra password changer ==

[ERROR] IP address is invalid.
[ERROR] Password is invalid! Please enter a 4-digit number.

OSError / device offline

$ ./bin/zebra-password-changer <IP_ADDRESS> <PASSWORD>
== Zebra password changer ==

[ERROR] Failed to connect: No route to host

version command

$ ./bin/zebra-password-changer version
== Zebra password changer ==

VERSION
    zebra-password-changer v0.1.0 - linux-amd64 nim-v1.6.6

help command

$ ./bin/zebra-password-changer help
== Zebra password changer ==

USAGE
    zebra-password-changer <IP_ADDRESS> <PASSWORD>
    zebra-password-changer  [command]

COMMANDS
    help     show CLI help
    version  show CLI version

DESCRIPTION
    CLI tool that allows changing Zebra printer's password

πŸ’₯ Features

  • Simple CLI colours
  • Argument checks & help command
  • Ip address validation
  • Password validation

🎯 Tested Zebra printer models

  • ZD 620 - ZD 621
  • GK 420d

🀝 Contributing

Before contributing issues or pull requests, could you review the Contributing Guidelines first?

πŸ’¬ Questions?

Feel free to open an issue.

🀩 Support

πŸ’™ If you like this project, give it a ⭐ and share it with friends!

πŸ›οΈ License

This project is open-sourced software licensed under the MIT license.

About

πŸ–₯ [Nim] [CLI] CLI tool that allows changing Zebra printers password. (nim)

Topics

Resources

License

Code of conduct

Stars

Watchers

Forks

Releases

No releases published

Sponsor this project

 

Packages

No packages published

Languages