File tree Expand file tree Collapse file tree 3 files changed +11
-11
lines changed
Expand file tree Collapse file tree 3 files changed +11
-11
lines changed Original file line number Diff line number Diff line change 11import * as fs from "node:fs" ;
2- import { exec as nodeExec } from "node:child_process" ;
3- import { promisify } from "node:util" ;
42import { type Config } from "../types/config" ;
53
64export const cwd = ( ) : string => {
@@ -34,11 +32,3 @@ export const writeFile = (
3432) : void => {
3533 fs . writeFileSync ( filePath ( config , filename ) , content ) ;
3634} ;
37-
38- export const exec = async ( command : string ) : Promise < string > => {
39- const execAsync = promisify ( nodeExec ) ;
40-
41- const { stdout } = await execAsync ( command ) ;
42-
43- return stdout . toString ( ) . trim ( ) ;
44- } ;
Original file line number Diff line number Diff line change 1+ import { promisify } from 'node:util'
2+ import { exec as nodeExec } from 'node:child_process'
3+
4+ export const exec = async ( command : string ) : Promise < string > => {
5+ const execAsync = promisify ( nodeExec ) ;
6+
7+ const { stdout } = await execAsync ( command ) ;
8+
9+ return stdout . toString ( ) . trim ( ) ;
10+ } ;
Original file line number Diff line number Diff line change 11import type { Config } from "../types/config" ;
2- import { exec } from "./filesystem" ;
32import { randomizer } from "./randomizer" ;
43import type { GitHub } from "@actions/github/lib/utils" ;
54import type { RestEndpointMethodTypes } from "@octokit/plugin-rest-endpoint-methods/dist-types/generated/parameters-and-response-types" ;
5+ import { exec } from './processes'
66
77export class Repository {
88 private _config : Config ;
You can’t perform that action at this time.
0 commit comments