https://github.com/SilinMeng0510/imgcatr Skip to content Toggle navigation Sign in * Product + Actions Automate any workflow + Packages Host and manage packages + Security Find and fix vulnerabilities + Codespaces Instant dev environments + Copilot Write better code with AI + Code review Manage code changes + Issues Plan and track work + Discussions Collaborate outside of code Explore + All features + Documentation + GitHub Skills + Blog * Solutions For + Enterprise + Teams + Startups + Education By Solution + CI/CD & Automation + DevOps + DevSecOps Resources + Learning Pathways + White papers, Ebooks, Webinars + Customer Stories + Partners * Open Source + GitHub Sponsors Fund open source developers + The ReadME Project GitHub community articles Repositories + Topics + Trending + Collections * Pricing Search or jump to... Search code, repositories, users, issues, pull requests... Search [ ] Clear Search syntax tips Provide feedback We read every piece of feedback, and take your input very seriously. [ ] [ ] Include my email address so I can be contacted Cancel Submit feedback Saved searches Use saved searches to filter your results more quickly Name [ ] Query [ ] To see all available qualifiers, see our documentation. Cancel Create saved search Sign in Sign up You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session. Dismiss alert {{ message }} SilinMeng0510 / imgcatr Public * Notifications * Fork 4 * Star 159 * cat for images, by RUST [?] License MIT license 159 stars 4 forks Branches Tags Activity Star Notifications * Code * Issues 1 * Pull requests 0 * Actions * Projects 0 * Security * Insights Additional navigation options * Code * Issues * Pull requests * Actions * Projects * Security * Insights SilinMeng0510/imgcatr This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository. main BranchesTags Go to file Code Folders and files Name Name Last commit Last commit message date Latest commit History 28 Commits .github/workflows .github/ workflows assets assets src src .gitignore .gitignore CHANGELOG.md CHANGELOG.md Cargo.toml Cargo.toml LICENSE LICENSE README.md README.md View all files Repository files navigation * README * MIT license ImgCatr Licence Crates.io version A CLI application imgcatr for displaying images. running `imgcatr cat.png` Install Crate.io (Recommended) Install from Crate.io, it's required to have Cargo on your computer. cargo install imgcatr On MacOS 1. Open Terminal 2. Use curl to Download the Release curl -L https://github.com/SilinMeng0510/imgcatr/releases/download/v0.1.4/imgcatr-x86_64-apple-darwin.tar.gz -o imgcatr-x86_64-apple-darwin.tar.gz 3. Extract the Tarball tar -xzf imgcatr-x86_64-apple-darwin.tar.gz 4. Move the Binary to a bin Directory mv imgcatr /usr/local/bin/ On Linux 1. Open Terminal 2. Use curl to Download the Release curl -L https://github.com/SilinMeng0510/imgcatr/releases/download/v0.1.4/imgcatr-x86_64-unknown-linux-gnu.tar.gz -o imgcatr-x86_64-unknown-linux-gnu.tar.gz 3. Extract the Tarball tar -xzf imgcatr-x86_64-unknown-linux-gnu.tar.gz 4. Move the Binary to a bin Directory sudo mv imgcatr /usr/local/bin/ On Windows 1. Using PowerShell (Windows 10 and later): 2. Use the Invoke-WebRequest cmdlet to download: Invoke-WebRequest -Uri https://github.com/SilinMeng0510/imgcatr/releases/download/v0.1.4/imgcatr-x86_64-pc-windows-msvc.zip -OutFile imgcatr-windows.zip 3. Extract zip file Expand-Archive -LiteralPath imgcatr-windows.zip -DestinationPath imgcatr-windows (Optional) Create a directory (if you don't already have one): New-Item -ItemType Directory -Force -Path "C:\Tools" Move imgcatr.exe: Move-Item imgcatr-windows\imgcatr.exe C:\Tools\ Usage Overview After installing the command on your computer's bin directory, you can directly call imgcatr on CLI with the following instructions to display your images. Usage: imgcatr [OPTIONS] Arguments: Image file to display Options: -s, --size Image size to display [default: 138x22] -f, --force Don't preserve the image's aspect ratio -a, --ansi Force output ANSI escape [possible values: truecolor, simple-black, simple-white, ascii] -h, --help Print help -V, --version Print version There are some features that you can customize how you would like to display the image. You can follow my documentation below to get more information on this command. Display Format With the preparation of the image, you can specify the output format with -a or -ansi, where Imgcatr has 4 available output formats: truecolor, simple-black, simple-white, ascii, and no_ansi (For Windows OS). running `imgcatr cat.png` Customized Size The default size of the image display is set to the size of the CLI. This means that the height of your image will not go beyond the height of your terminal. However, you can specify the image size with -s or -size followed by input in format. An example is provided below, where the image size is set to 100x100. imgcatr cat.png --size 100x100 Ratio Preserve The image ratio is preserved as default. And option -f or -force can force the program to not preserve the image ratio. running `imgcatr cat.png` Additional Comments Special Thanks This work is derived from an open-sourced project named termimage. Here, I'm offering my special thanks to the team. Comparison The previous work termimage uses an older version of the clap-v2 crate(library). imgcatr replaces clap-v2 with the latest implementation of clap-v4, which has better performance overall. In addition, imgcatr offers a new feature in which users can display the ASCII format of images. The Future There will be potential improvement in future work with faster API and more features available. About cat for images, by RUST [?] Resources Readme License MIT license Activity Stars 159 stars Watchers 1 watching Forks 4 forks Report repository Releases 3 v0.1.4 Latest Jan 4, 2024 + 2 releases Packages 0 No packages published Languages * Rust 100.0% Footer (c) 2024 GitHub, Inc. Footer navigation * Terms * Privacy * Security * Status * Docs * Contact * Manage cookies * Do not share my personal information You can't perform that action at this time.