Socket
Book a DemoInstallSign in
Socket

@technote-space/github-action-log-helper

Package Overview
Dependencies
Maintainers
1
Versions
73
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@technote-space/github-action-log-helper

Logging helpers for GitHub Actions.

latest
Source
npmnpm
Version
0.2.19
Version published
Weekly downloads
256
-80.05%
Maintainers
1
Weekly downloads
 
Created
Source

Github Action Log Helper

npm version CI Status codecov CodeFactor License: MIT

Read this in other languages: English, 日本語.

Logging helpers for GitHub Actions.

Table of Contents

Details

Install

yarn

  • yarn add @technote-space/github-action-log-helper

npm

  • npm i @technote-space/github-action-log-helper

Logger

import { Logger } from '@technote-space/github-action-log-helper';

const logger = new Logger();
logger.startProcess('Process name');
logger.displayCommand('command');
logger.displayStdout('stdout1\nstdout2');
logger.displayStderr('stderr1\nstderr2');
logger.log();
logger.info('output info');
logger.endProcess();

// ::group::Process name
// [command]command
//   >> stdout1
//   >> stdout2
// ::warning::  >> stderr1
// ::warning::  >> stderr2
// 
// > output info
// ::endgroup::

logger.getColorString('colored text', 'green'); // Color: 'black' | 'red' | 'green' | 'yellow' | 'blue' | 'magenta' | 'cyan' | 'white'
logger.getColorString('colored text', 'yellow', 'underline'); // Attribute: 'bold' | 'underline' | 'italic'
logger.c('colored text', 'yellow', 'underline'); // alias

Author

GitHub (Technote)
Blog

Keywords

github

FAQs

Package last updated on 27 May 2023

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts