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

gh-short-url

v0.1.3

Published

A command line tool that use github pages to convert short url

Downloads

7

Readme

gh-short-url

A command line tool that use github pages to convert short url.

Before Use

  1. Fork the gh-pages-url-shortener, if you don't have your own domain name, I recommend you fork this link repository I created.

  2. Fork the gh-pages-url-shortener-db, it's an empty repository, you can also just create a repository like this, the name doesn't have to be the same.

  3. Open the repository you forked in step 1, and modify the 404.html file.

- var GITHUB_ISSUES_LINK = "https://api.github.com/repos/nelsontky/gh-pages-url-shortener-db/issues/";
+ var GITHUB_ISSUES_LINK = "https://api.github.com/repos/${your name}/${your db repo}/issues/";
  1. Now, try to open an issue in the repository you created in step 2. The issue title should be a valid url, the body can be empty. Then you can use ${username}.github.io/${link repo}/1 to access the url you entered in the issue title. Mabye the link is still too long and you should use your own domain name.

More Detail: gh-pages-url-shortener

How to use

Almost forgot, you need to install the GitHub CLI before you use this command line tool.

Let do it!

# install package
npm install gh-short-url -g
# config your url database repository and github user name and github pages domain
# example: shorten config --database="gh-pages-url-shortener-db" --user="mayandev" --pages="mayandev.github.io/link/"
shorten config --database=${db-repo-name} --user=${username} --pages=${domain/url-repo/}
# shorten it
shorten https://en.wikipedia.org/wiki/Kobe_Bryant#Basketball_legacy/
# you can also use surl
surl https://en.wikipedia.org/wiki/Kobe_Bryant#Basketball_legacy

image

How does this work

Thank to gh-pages-url-shortener for the ideas.