Skip to content

Display custom files and Combine multiple files in terminal using "lcat" command.

Notifications You must be signed in to change notification settings

lakshygupta/Custom-Terminal-Commands

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Custom Terminal Commands using NodeJS πŸš€

It is used to display or make a copy content of one or more files in the terminal.

Custom Commands Implemented

Main Commands

  1. lcat "filepath" β†’ displays content of the file in the terminal
  2. lcat "filepath1" "filepath2" "filepath3" ... β†’ displays content of all files in the terminal(contactinated form) in the given order
  3. lcat -s "filepath" β†’ convert bigger line breaks into a singular line break
  4. lcat -n "filepath" β†’ give numbering to all the lines
  5. lcat -b "filepath" β†’ give numbering to non-empty lines
  6. lcat "filePath" > filename2Path β†’ put all the content of filename into filename2Path by overriding and also creates filename2 if it doesn't exist
  7. lcat "filePath" >> filename2Path β†’ append all the content of filename into filename2Path and also creates filename2 if it doesn't exist
  8. lcat -s "filename" > filename2 β†’ get the file content of filename remove large spaces and save the output in filename2

Combine Multiple Commands

  1. lcat -s -n "filepath" "filepath2" ... β†’ convert bigger line breaks into a singular line break and give numbering to all the lines
  2. lcat -s -b "filepath" "filepath2" ... β†’ convert bigger line breaks into a singular line break and give numbering to non-empty lines

-s , -n and -b order do not matter, Write them anywhere in the query.

How to install

  • Clone this repository.
  • Make sure you have latest version of Node.js LTS installed in your system.
  • Open the CMD/Terminal in the folder and run the command npm link
  • It will make lcat as a global command on your system. (lcat is small 'L' cat)
  • That's it.

Images

Main Commands

1 2 3

Combine Multiple Commands

4

Order of -s and -n in command query do not matter.

5

Command 6

6

NewFile is created

7

About

Display custom files and Combine multiple files in terminal using "lcat" command.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published