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

ak-squash

v1.2.6

Published

Creating local alias for commands

Downloads

35

Readme

Squash :tada:

Build NPM Downloads Package Size NPM Version Contributors Commit Node Version

Let's squash your commands.

Squash allows you to give a custom name to your shell commands. These commands can be run using the custom name.

Give us a :star: if you like our work :heart:

Install

$ npm i -g ak-squash

Setup

  • Export the squash path, to make the commands executable.

    export PATH=$PATH:/usr/local/.squash

    To make this export permanent read here

  • Now try running squash --help. This should display details on using squash

  • This completes your setup

Usage

Once you are done with the setup. You can start giving custom names to your commands.

You can find example usage of all the available features of squash here

Syntax for using squash is

squash {{COMMAND}} --alias={{NAME_FOR_COMMAND}}

  • COMMAND: The shell command which will be given a name
  • NAME_FOR_COMMAND: The custom name

Note: You can wrap the command between "COMMAND" if the command contains any types of quotes or spaces

Example

$ squash ls /home/squash --alias=list_squash

Now for using above created command just run

$ list_squash

Available Flags

Flags that require parameters

squash {{COMMAND}} --{{FLAG}}={{NAME_FOR_COMMAND}}
  • alias: to give name to a command
  • rm: removes a previously squashed command

Flags without parameters

squash --{{FLAG}}
  • help: gets help for squash
  • list: lists all the created commands
  • system-alias: lists all the system reserved aliases
  • pass-args: arguments called on the alias will be passed to the command. Use when creating the alias

Limitations

  • It does not work in Windows.
  • It does not support the cd command
  • Manually exporting the path /usr/local/.squash is very important.

Contributing

We are constantly working on improving squash and we need all the help we can get. You can contribute to this project by giving suggestions, fixing open issues or by implementing a new feature. Read our contibution guide here

Contributors

Thank you to all the contributors who help in making this project better :raised_hands: