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

trigitactions

v1.0.3

Published

Trigger git actions with cli

Downloads

3

Readme

#Trigitactions

⭐ Star us on GitHub — it helps! Trigitactions is a cli to trigger github actions from terminal, npm / yarn script with just one line.

It uses @ocktokit under the hood and can be launched in 1 min.

Installation

npm i -g trigitactions
yarn global add trigitactions

One installed you have 3 commands:

  • trigit: help menu for trigitactions cli
  • runworkflow: Run a workflow on github actions
  • listworflow: List for a given repository all worklow.id, worklow.name and worklow.filename

##Commands ###Auth To interact with Github api, you need to setup an env variable with a github token value. You can generate a token there: https://github.com/settings/tokens

###listworkflow This command helps you to list all workflow in a repository.

listworkflow -o Owner -r Repository -p Profile -q search_term

Owner and Repository are required.

Profile is not required, but you need to setup an env variable named TRIGIT_DEFAULT_PROFILE with a valid github token. If your already have an env variable with a valid github token value, just use:

-p YOUR_ENV_VARIABLE_NAME

If you are looking for a particular workflow, you can use the -q parameter. It's a simple filter as workflow.name.toLowerCase().includes(q).

Example

listworkflow -o JohnDoe -r FirstCorp
----------------------------------------
Output:
Owner: JohnDoe | Repo: FirstCorp
Workflow found: 3
id: 1637264 | name: Build/company1 | filename: buildcompany1.yml
id: 6173621 | name: Build/company2 | filename: buildcompany2.yml

###runworkflow This command helps you to trigger a github action.

runworkflow  -o Owner -r Repository -w WorkflowId -i 'DataForJob:JSON' -f master

Owner and Repository are required. This command uses the same config for -p variable as listworfklow command.

-w variable is the workflow id to trigger. You can use workflow.name or wrkflow.filename given in listworfklow command.

-i variable is for workflow input. To use this parameters, you need to define input in your .yml file, otherwise an error will be throw. Data should be passed as a JSON string: -i '{"url": "http://example"}'

-f is for ref. By default this will be set to master, you can use any branch or tag name.

runworkflow -o JohnDoe -r company1 -w 6176732 -i '{"dbUrl": "mydb.com"}' -f dev
----------------------------------------
Output:
Status: 204. Action triggered 👍