mirror of
https://code.forgejo.org/pnpm/action-setup.git
synced 2025-05-20 05:14:45 +00:00
Make logs foldable
This commit is contained in:
parent
6eb237a86d
commit
83681c63a7
4 changed files with 11 additions and 6 deletions
|
@ -1,5 +1,5 @@
|
|||
import { spawnSync } from 'child_process'
|
||||
import { warning } from '@actions/core'
|
||||
import { warning, startGroup, endGroup } from '@actions/core'
|
||||
import { Inputs } from '../inputs'
|
||||
import { patchPnpmEnv } from '../utils'
|
||||
|
||||
|
@ -9,12 +9,13 @@ export function pruneStore(inputs: Inputs) {
|
|||
return
|
||||
}
|
||||
|
||||
console.log('Running pnpm store prune')
|
||||
startGroup('Running pnpm store prune...')
|
||||
const { error, status } = spawnSync('pnpm', ['store', 'prune'], {
|
||||
stdio: 'inherit',
|
||||
shell: true,
|
||||
env: patchPnpmEnv(inputs)
|
||||
})
|
||||
endGroup()
|
||||
|
||||
if (error) {
|
||||
warning(error)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue