npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

Iโ€™ve always been into building performant and accessible sites, but lately Iโ€™ve been taking it extremely seriously. So much so that Iโ€™ve been building a tool to help me optimize and monitor the sites that I build to make sure that Iโ€™m making an attempt to offer the best experience to those who visit them. If youโ€™re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, ๐Ÿ‘‹, Iโ€™m Ryan Hefnerย  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If youโ€™re interested in other things Iโ€™m working on, follow me on Twitter or check out the open source projects Iโ€™ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soonโ€“ish.

Open Software & Tools

This site wouldnโ€™t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you ๐Ÿ™

ยฉ 2024 โ€“ย Pkg Stats / Ryan Hefner

nodcat

v1.1.0

Published

This Node.js script mimics the `cat` command in Linux, allowing you to read from a file or standard input and print the output with colored text. You can read larger file content without any problem even 10gb or larger ๐Ÿ™‚

Downloads

63

Readme

Linux Cat Commad Clone Using Raw Node.js

This Node.js script mimics the cat command in Linux, allowing you to read from a file or standard input and print the output with colored text.

You can read larger file content without any problem even 10gb or larger ๐Ÿ™‚

Features

  • Reads from a file and outputs the content to the console.
  • Colors the output text using ANSI escape codes.
  • Converts stdin input to uppercase and colors it before printing.
  • Allows changing the file path dynamically by entering path:<filePath>.

you can install using npm also.

npm i nodcat

Usage if you install with npm

if you install it globally or locally then you can simply use nodcat <pathname> or

nodcat
path:<filename> like ./learning.c

Installation

  1. Clone the repository:

    git clone https://github.com/omorhawlader/CLI-using-nodejs-linux-cat-command-clone-with-extra-
    

    cd node-cat-command

Install dependencies

npm install

Usage

1.Run the script with a file path as an argument:

node cat.js <filePath>

Example:

node cat.js example.txt

2.Run the script and provide input via stdin:

node cat.js

Type the text and press Enter to see the colored uppercase output.

  1. Change the file path dynamically:
node cat.js

Enter path: to read from a new file.

Example

1.Reading from a file:

node cat.js example.txt
  1. Using stdin:
node cat.js

Input:

omar

Output:

OMAR

3.Changing file path dynamically:

node cat.js

Input:

path:example.txt

Contact