Skip to content

Commit

Permalink
ogma-core: Modify reqs DB command to allow customizing target filenam…
Browse files Browse the repository at this point in the history
…e. Refs #80.

Ogma does not allow users to specify the name of the target file that should be
used in applications produced from FRET files. Without that extra facility, it
becomes necessary to rename and modify the Copilot/Haskell (or C) files
produced, which detracts from a smooth UX process.

This commit modifies the top-level command that exposes the requirements DB
backend to customize the name of the target C filenames based on an argument to
the backend, and use it when calling the internal FRET-to-Copilot translation
module.
  • Loading branch information
ivanperez-keera committed May 21, 2023
1 parent 8ef2d1e commit b3395b6
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions ogma-core/src/Command/FRETReqsDB2Copilot.hs
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ fretReqsDB2Copilot fp useCoCoSpec = do
-- to Copilot code.
data FRETReqsDB2CopilotOptions = FRETReqsDB2CopilotOptions
{ fretReqsDB2CopilotUseCoCoSpec :: Bool
, fretReqsDB2CopilotFilename :: String
}

-- | Parse a JSON file containing a FRET requirement database.
Expand Down Expand Up @@ -127,6 +128,7 @@ fretReqsDB2CopilotOptions :: FRETReqsDB2CopilotOptions
fretReqsDB2CopilotOptions options =
T.FRETReqsDB2CopilotOptions
(fretReqsDB2CopilotUseCoCoSpec options)
(fretReqsDB2CopilotFilename options)

-- * Result

Expand Down

0 comments on commit b3395b6

Please sign in to comment.