Skip to content

Commit

Permalink
[#66] Move Headroom.FileSystem module
Browse files Browse the repository at this point in the history
  • Loading branch information
vaclavsvejcar committed Mar 31, 2021
1 parent 0cefffe commit ceeb3b6
Show file tree
Hide file tree
Showing 13 changed files with 23 additions and 23 deletions.
6 changes: 3 additions & 3 deletions headroom.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ cabal-version: 2.2
--
-- see: https://github.com/sol/hpack
--
-- hash: fad870155d9e943ea6729ce0b1fc7ab981a153d1052565d791a1ab6116685bd0
-- hash: 15e44f0979eea1408d7d0b5e7cbb1a35ccd2d348ed4e9668f6f6edf6131efada

name: headroom
version: 0.4.2.0
Expand Down Expand Up @@ -170,7 +170,6 @@ library
Headroom.FileSupport.Shell
Headroom.FileSupport.TemplateData
Headroom.FileSupport.Types
Headroom.FileSystem
Headroom.FileType
Headroom.FileType.Types
Headroom.Header
Expand All @@ -179,6 +178,7 @@ library
Headroom.HeaderFn
Headroom.HeaderFn.Types
Headroom.HeaderFn.UpdateCopyright
Headroom.IO.FileSystem
Headroom.Meta
Headroom.Meta.Version
Headroom.SourceCode
Expand Down Expand Up @@ -277,13 +277,13 @@ test-suite spec
Headroom.FileSupport.ScalaSpec
Headroom.FileSupport.ShellSpec
Headroom.FileSupportSpec
Headroom.FileSystemSpec
Headroom.FileTypeSpec
Headroom.Header.SanitizeSpec
Headroom.HeaderFn.TypesSpec
Headroom.HeaderFn.UpdateCopyrightSpec
Headroom.HeaderFnSpec
Headroom.HeaderSpec
Headroom.IO.FileSystemSpec
Headroom.Meta.VersionSpec
Headroom.SourceCodeSpec
Headroom.Template.MustacheSpec
Expand Down
6 changes: 3 additions & 3 deletions src/Headroom/Command/Init.hs
Original file line number Diff line number Diff line change
Expand Up @@ -54,13 +54,13 @@ import Headroom.Embedded ( configFileStub
, defaultConfig
, licenseTemplate
)
import Headroom.FileSystem ( FileSystem(..)
import Headroom.FileType ( fileTypeByExt )
import Headroom.FileType.Types ( FileType(..) )
import Headroom.IO.FileSystem ( FileSystem(..)
, fileExtension
, findFiles
, mkFileSystem
)
import Headroom.FileType ( fileTypeByExt )
import Headroom.FileType.Types ( FileType(..) )
import Headroom.Meta ( TemplateType
, buildVersion
, configFileName
Expand Down
10 changes: 5 additions & 5 deletions src/Headroom/Command/Run.hs
Original file line number Diff line number Diff line change
Expand Up @@ -66,11 +66,6 @@ import Headroom.Embedded ( defaultConfig
import Headroom.FileSupport ( analyzeSourceCode
, fileSupport
)
import Headroom.FileSystem ( FileSystem(..)
, excludePaths
, fileExtension
, mkFileSystem
)
import Headroom.FileType ( fileTypeByExt )
import Headroom.FileType.Types ( FileType(..) )
import Headroom.Header ( addHeader
Expand All @@ -86,6 +81,11 @@ import Headroom.Header.Types ( HeaderInfo(..)
import Headroom.HeaderFn ( mkConfiguredEnv
, postProcessHeader
)
import Headroom.IO.FileSystem ( FileSystem(..)
, excludePaths
, fileExtension
, mkFileSystem
)
import Headroom.Meta ( TemplateType
, configFileName
, productInfo
Expand Down
4 changes: 2 additions & 2 deletions src/Headroom/FileSystem.hs → src/Headroom/IO/FileSystem.hs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
{-# LANGUAGE ViewPatterns #-}

{-|
Module : Headroom.FileSystem
Module : Headroom.IO.FileSystem
Description : Operations related to files and file system
Copyright : (c) 2019-2021 Vaclav Svejcar
License : BSD-3-Clause
Expand All @@ -14,7 +14,7 @@ Module providing functions for working with the local file system, its file and
directories.
-}

module Headroom.FileSystem
module Headroom.IO.FileSystem
( -- * Type Aliases
CreateDirectoryFn
, DoesFileExistFn
Expand Down
2 changes: 1 addition & 1 deletion test/Headroom/Command/InitSpec.hs
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ import Headroom.Data.Has ( Has(..) )
import Headroom.Data.Lens ( suffixLenses
, suffixLensesFor
)
import Headroom.FileSystem ( FileSystem(..) )
import Headroom.FileType.Types ( FileType(..) )
import Headroom.IO.FileSystem ( FileSystem(..) )
import RIO
import RIO.FilePath ( (</>) )
import qualified RIO.List as L
Expand Down
2 changes: 1 addition & 1 deletion test/Headroom/Command/RunSpec.hs
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,8 @@ import Headroom.Data.Lens ( suffixLenses
)
import Headroom.Data.Regex ( re )
import Headroom.Data.Text ( fromLines )
import Headroom.FileSystem ( FileSystem(..) )
import Headroom.FileType.Types ( FileType(..) )
import Headroom.IO.FileSystem ( FileSystem(..) )
import Headroom.Meta ( TemplateType )
import Headroom.Template ( Template(..) )
import Headroom.Types ( CurrentYear(..) )
Expand Down
2 changes: 1 addition & 1 deletion test/Headroom/FileSupport/Haskell/HaddockSpec.hs
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ import Headroom.FileSupport.Haskell.Haddock
import Headroom.FileSupport.TemplateData ( HaddockOffsets(..)
, TemplateData(..)
)
import Headroom.FileSystem ( loadFile )
import Headroom.FileType.Types ( FileType(..) )
import Headroom.IO.FileSystem ( loadFile )
import Headroom.Template ( Template(..) )
import Headroom.Template.Mustache ( Mustache(..) )
import RIO
Expand Down
2 changes: 1 addition & 1 deletion test/Headroom/FileSupport/HaskellSpec.hs
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,9 @@ import Headroom.FileSupport.TemplateData ( HaddockOffsets(..)
import Headroom.FileSupport.Types ( FileSupport(..)
, SyntaxAnalysis(..)
)
import Headroom.FileSystem ( loadFile )
import Headroom.FileType.Types ( FileType(..) )
import Headroom.Header ( extractHeaderTemplate )
import Headroom.IO.FileSystem ( loadFile )
import Headroom.Template ( Template(..)
, emptyTemplate
)
Expand Down
2 changes: 1 addition & 1 deletion test/Headroom/FileSupport/JavaSpec.hs
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@ import Headroom.FileSupport.TemplateData ( TemplateData(..) )
import Headroom.FileSupport.Types ( FileSupport(..)
, SyntaxAnalysis(..)
)
import Headroom.FileSystem ( loadFile )
import Headroom.FileType.Types ( FileType(..) )
import Headroom.Header ( extractHeaderTemplate )
import Headroom.IO.FileSystem ( loadFile )
import Headroom.Template ( emptyTemplate )
import Headroom.Template.Mustache ( Mustache )
import Headroom.Variables ( mkVariables )
Expand Down
2 changes: 1 addition & 1 deletion test/Headroom/FileSupport/PureScriptSpec.hs
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@ import Headroom.FileSupport.TemplateData ( TemplateData(..) )
import Headroom.FileSupport.Types ( FileSupport(..)
, SyntaxAnalysis(..)
)
import Headroom.FileSystem ( loadFile )
import Headroom.FileType.Types ( FileType(..) )
import Headroom.Header ( extractHeaderTemplate )
import Headroom.IO.FileSystem ( loadFile )
import Headroom.Template ( emptyTemplate )
import Headroom.Template.Mustache ( Mustache )
import Headroom.Variables ( mkVariables )
Expand Down
2 changes: 1 addition & 1 deletion test/Headroom/FileSupportSpec.hs
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ module Headroom.FileSupportSpec
where

import Headroom.FileSupport
import Headroom.FileSystem ( loadFile )
import Headroom.FileType.Types ( FileType(..) )
import Headroom.IO.FileSystem ( loadFile )
import Headroom.SourceCode ( LineType(..)
, SourceCode(..)
)
Expand Down
2 changes: 1 addition & 1 deletion test/Headroom/HeaderSpec.hs
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,10 @@ import Headroom.Embedded ( defaultConfig )
import Headroom.FileSupport ( analyzeSourceCode
, fileSupport
)
import Headroom.FileSystem ( loadFile )
import Headroom.FileType.Types ( FileType(..) )
import Headroom.Header
import Headroom.Header.Types ( HeaderInfo(..) )
import Headroom.IO.FileSystem ( loadFile )
import Headroom.SourceCode ( LineType(..)
, SourceCode(..)
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE QuasiQuotes #-}

module Headroom.FileSystemSpec
module Headroom.IO.FileSystemSpec
( spec
)
where

import Headroom.Data.Regex ( re )
import Headroom.FileSystem
import Headroom.IO.FileSystem
import RIO
import RIO.FilePath ( (</>) )
import RIO.List ( sort )
Expand Down

0 comments on commit ceeb3b6

Please sign in to comment.