File tree Expand file tree Collapse file tree
packages/app/src/lib/usecases/actions Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -2,7 +2,7 @@ import type * as CommandExecutor from "@effect/platform/CommandExecutor"
22import type { PlatformError } from "@effect/platform/Error"
33import * as FileSystem from "@effect/platform/FileSystem"
44import * as Path from "@effect/platform/Path"
5- import { Effect , Either } from "effect"
5+ import { Effect } from "effect"
66
77import type { CreateCommand , ParseError } from "../../core/domain.js"
88import { deriveRepoPathParts } from "../../core/domain.js"
@@ -57,8 +57,10 @@ const resolveClonedOnHostname = (): Effect.Effect<string | undefined> =>
5757 try : ( ) => import ( "node:os" ) . then ( ( os ) => os . hostname ( ) ) ,
5858 catch : ( ) => new Error ( "hostname lookup failed" )
5959 } ) . pipe (
60- Effect . either ,
61- Effect . map ( ( result ) => Either . match ( result , { onLeft : ( ) => undefined , onRight : ( hostname ) => hostname } ) )
60+ Effect . match ( {
61+ onFailure : ( ) : string | undefined => undefined ,
62+ onSuccess : ( hostname ) : string | undefined => hostname
63+ } )
6264 )
6365
6466const makeCreateContext = ( path : Path . Path , baseDir : string ) : CreateContext => {
You can’t perform that action at this time.
0 commit comments