mirror of
https://github.com/pnpm/action-setup.git
synced 2024-12-23 00:06:30 +08:00
Complete source code
This commit is contained in:
parent
7d62586afe
commit
696222a6f3
|
@ -1,11 +1,13 @@
|
|||
import { setFailed } from '@actions/core'
|
||||
import getInputs from './inputs'
|
||||
import setOutputs from './outputs'
|
||||
import install from './install'
|
||||
|
||||
const inputs = getInputs()
|
||||
|
||||
install(inputs).then(() => {
|
||||
console.log('Installation Completed!')
|
||||
setOutputs(inputs)
|
||||
}).catch(error => {
|
||||
console.error(error)
|
||||
setFailed(error)
|
||||
|
|
8
src/outputs/index.ts
Normal file
8
src/outputs/index.ts
Normal file
|
@ -0,0 +1,8 @@
|
|||
import { addPath } from '@actions/core'
|
||||
import { Inputs } from '../inputs'
|
||||
|
||||
export function setOutputs(inputs: Inputs) {
|
||||
addPath(inputs.binDest)
|
||||
}
|
||||
|
||||
export default setOutputs
|
Loading…
Reference in New Issue
Block a user