Something went wrong. Try again.
Dagger 1.0.0 beta SDK experiments
dagger purescript gleam clojure
Something went wrong. Try again.
3.2 kB · 75 lines
at main
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576-- Generated by scripts/generate.mjs. Do not edit.module Dagger.CurrentModule ( contextDirectory , dependencies , generatedContextDirectory , id , name , source , sourceSubpath , workdir , workdirWith , WorkdirOpts , defaultWorkdirOpts , workdirFile ) where
import Data.Maybe (Maybe(..))import Effect.Aff (Aff)import Dagger.Internal.Runtime as Rimport Dagger.Types as T
-- | The module's context directory loaded into the engine (plus any generated code that may have been created).-- |-- | It holds the module's source code and every other file the engine loaded for the module, at their paths relative to the context root. Use sourceSubpath to locate the source code in it.contextDirectory :: T.CurrentModule -> T.DirectorycontextDirectory = R.select "contextDirectory" []
-- | The dependencies of the module.dependencies :: T.CurrentModule -> Aff (Array T.Module)dependencies = R.objectList "Module" "dependencies" []
-- | The generated files and directories made on top of the module source's context directory.generatedContextDirectory :: T.CurrentModule -> T.DirectorygeneratedContextDirectory = R.select "generatedContextDirectory" []
-- | A unique identifier for this CurrentModule.id :: T.CurrentModule -> Aff T.IDid = R.scalar "id" []
-- | The name of the module being executed inname :: T.CurrentModule -> Aff Stringname = R.scalar "name" []
-- | The directory containing the module's source code loaded into the engine (plus any generated code that may have been created).source :: T.CurrentModule -> T.Directorysource = R.select "source" []
-- | The path to the directory containing the module's source code, relative to the context directory.sourceSubpath :: T.CurrentModule -> Aff StringsourceSubpath = R.scalar "sourceSubpath" []
type WorkdirOpts = { exclude :: Maybe (Array String) , include :: Maybe (Array String) , gitignore :: Maybe Boolean }
defaultWorkdirOpts :: WorkdirOptsdefaultWorkdirOpts = { exclude: Nothing , include: Nothing , gitignore: Nothing }
-- | Load a directory from the module's scratch working directory, including any changes that may have been made to it during module function execution.workdir :: String -> T.CurrentModule -> T.Directoryworkdir argPath = workdirWith argPath defaultWorkdirOpts
-- | Load a directory from the module's scratch working directory, including any changes that may have been made to it during module function execution.workdirWith :: String -> WorkdirOpts -> T.CurrentModule -> T.DirectoryworkdirWith argPath opts = R.select "workdir" [R.argument "path" "String!" argPath, R.optional (R.argument "exclude" "[String!]") opts.exclude, R.optional (R.argument "include" "[String!]") opts.include, R.optional (R.argument "gitignore" "Boolean") opts.gitignore]
-- | Load a file from the module's scratch working directory, including any changes that may have been made to it during module function execution.Load a file from the module's scratch working directory, including any changes that may have been made to it during module function execution.workdirFile :: String -> T.CurrentModule -> T.FileworkdirFile argPath = R.select "workdirFile" [R.argument "path" "String!" argPath]