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

git-suite

v0.8.0

Published

npm package to simplify git commit flow

Downloads

4

Readme

Git-Suite

A command line application to simplify the git workflow on committing, pushing and others commands.

Prerequisites

Install Node Package Manager npm and Node Version Manager nvm. Have git installed and configured on your machine.

Info

Exemple

Runs the command

$ gs -a -m "initial commit" --ft -p main -f

to get the following:

$ git add .
$ git commit -m "feat: initial commit"
$ git push -f origin main

Simple as that!

How to use

  1. Install using npm:
$ npm i git-suite
  1. Install globally:
$ npm install -g git-suite

Done! To see the list of all valid commands on terminal, run:

$ gs --help

Valid Commands

1. Git add: gs -a | -add [<file>,<file>] or - runs git add . by default. Specify files to add concatenating the paths with a comma, like gs -a path/to/file1.js,path/to/file2.js;

2. Git commit: gs -m | -message "message" [--ft | --fx | --c | --e] - runs git commit -m "message". If the commit type flag is specified, the final commit message will be:

  • --ft --> "feat: message";
  • --fx --> "fix: message";
  • --c --> "chore: message";
  • --e --> "enhance: message";
  • --d --> "docs: message";

3. Git push: gs -p | -push [<branch-name>] [-f | -force] - runs git push origin <branch-name>. The force flag and branch-name is optional;

⚠️ Warning!

Not providing the branch name will push the changes from the current branch.

4. Git reset HEAD: gs -rh | -reset-head [<number>] - runs git reset HEAD~<number>. By default, with remove 1 commit from the HEAD.

5. Git rebase: gs -r [head-branch] [branch-to-rebase] - runs:

  • Example 1: Rebase current branch (i.e. docs/readme) into default head branch (i.e. main):

      $ git -r
    
      git checkout main
      git pull origin main
      git checkout docs/readme
      git rebase main
  • Example 2: Rebase develop into main from any other branch:

    $ gs -r main develop
    
    git checkout main
    git pull origin main
    git checkout develop
    git rebase main

Runs the rebase process. It will update the head branch automatically for you and you dont need to worries aboute the update status of your head branch! Besides, it can be triggered from any branch, precisely because it makes the checkouts on the mentioned branchs, ensuring that the rebase process is performed to the correct ones.

Note: If any conflicts occur in the rebase process, it will stop to resolve the conflicts. After rebase, run gs -p -f to push the current branch.

6. Git checkout: gs -c <branch-name> - runs git checkout branch-name. Change to "brach-name" branch. It is allowed to create a new branch running gs -cb branch-name.

7. Git checkout default: gs -cd - runs git checkout <default-head- branch>. It will swich the current branch to the default head branch (i.e. main or master)