Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
haskell-gargantext
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
159
Issues
159
List
Board
Labels
Milestones
Merge Requests
9
Merge Requests
9
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
gargantext
haskell-gargantext
Commits
082be2c7
Commit
082be2c7
authored
Dec 09, 2024
by
Grégoire Locqueville
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove some more dead code, update `weeder.toml` again
parent
4366cb29
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
9 additions
and
29 deletions
+9
-29
Settings.hs
src/Gargantext/API/Admin/Settings.hs
+0
-19
PolicyCheck.hs
src/Gargantext/API/Auth/PolicyCheck.hs
+0
-7
weeder.toml
weeder.toml
+9
-3
No files found.
src/Gargantext/API/Admin/Settings.hs
View file @
082be2c7
...
@@ -19,8 +19,6 @@ module Gargantext.API.Admin.Settings
...
@@ -19,8 +19,6 @@ module Gargantext.API.Admin.Settings
where
where
import
Codec.Serialise
(
Serialise
(),
serialise
)
import
Data.ByteString.Lazy
qualified
as
L
import
Data.Pool
(
Pool
)
import
Data.Pool
(
Pool
)
import
Data.Pool
qualified
as
Pool
import
Data.Pool
qualified
as
Pool
import
Database.PostgreSQL.Simple
(
Connection
,
connect
,
close
,
ConnectInfo
)
import
Database.PostgreSQL.Simple
(
Connection
,
connect
,
close
,
ConnectInfo
)
...
@@ -34,9 +32,6 @@ import Gargantext.Core.NodeStory (fromDBNodeStoryEnv)
...
@@ -34,9 +32,6 @@ import Gargantext.Core.NodeStory (fromDBNodeStoryEnv)
import
Gargantext.Prelude
import
Gargantext.Prelude
import
Gargantext.System.Logging
(
Logger
)
import
Gargantext.System.Logging
(
Logger
)
import
Network.HTTP.Client.TLS
(
newTlsManager
)
import
Network.HTTP.Client.TLS
(
newTlsManager
)
import
System.Directory
(
renameFile
)
import
System.IO
(
hClose
)
import
System.IO.Temp
(
withTempFile
)
newtype
IniFile
=
IniFile
{
_IniFile
::
FilePath
}
newtype
IniFile
=
IniFile
{
_IniFile
::
FilePath
}
...
@@ -46,20 +41,6 @@ newtype IniFile = IniFile { _IniFile :: FilePath }
...
@@ -46,20 +41,6 @@ newtype IniFile = IniFile { _IniFile :: FilePath }
-- | RepoDir FilePath configuration
-- | RepoDir FilePath configuration
type
RepoDirFilePath
=
FilePath
type
RepoDirFilePath
=
FilePath
repoSnapshot
::
RepoDirFilePath
->
FilePath
repoSnapshot
repoDir
=
repoDir
<>
"/repo.cbor"
-- This assumes we own the lock on repoSnapshot.
repoSaverAction
::
RepoDirFilePath
->
Serialise
a
=>
a
->
IO
()
repoSaverAction
repoDir
a
=
do
withTempFile
repoDir
"tmp-repo.cbor"
$
\
fp
h
->
do
-- printDebug "repoSaverAction" fp
L
.
hPut
h
$
serialise
a
hClose
h
renameFile
fp
(
repoSnapshot
repoDir
)
newEnv
::
Logger
(
GargM
Env
BackendInternalError
)
->
GargConfig
->
D
.
Dispatcher
->
IO
Env
newEnv
::
Logger
(
GargM
Env
BackendInternalError
)
->
GargConfig
->
D
.
Dispatcher
->
IO
Env
newEnv
logger
config
dispatcher
=
do
newEnv
logger
config
dispatcher
=
do
...
...
src/Gargantext/API/Auth/PolicyCheck.hs
View file @
082be2c7
...
@@ -34,8 +34,6 @@ module Gargantext.API.Auth.PolicyCheck (
...
@@ -34,8 +34,6 @@ module Gargantext.API.Auth.PolicyCheck (
,
moveChecks
,
moveChecks
,
publishChecks
,
publishChecks
,
userMe
,
userMe
,
alwaysAllow
,
alwaysDeny
)
where
)
where
import
Control.Lens
(
view
)
import
Control.Lens
(
view
)
...
@@ -274,11 +272,6 @@ publishChecks :: NodeId -> BoolExpr AccessCheck
...
@@ -274,11 +272,6 @@ publishChecks :: NodeId -> BoolExpr AccessCheck
publishChecks
nodeId
=
publishChecks
nodeId
=
(
nodeUser
nodeId
`
BOr
`
nodeSuper
nodeId
)
(
nodeUser
nodeId
`
BOr
`
nodeSuper
nodeId
)
alwaysAllow
::
BoolExpr
AccessCheck
alwaysAllow
=
BConst
.
Positive
$
AC_always_allow
alwaysDeny
::
BoolExpr
AccessCheck
alwaysDeny
=
BConst
.
Positive
$
AC_always_deny
-------------------------------------------------------------------------------
-------------------------------------------------------------------------------
-- Instances
-- Instances
...
...
weeder.toml
View file @
082be2c7
type-class-roots
=
true
type-class-roots
=
true
roots
=
[
'^Main\.main$'
roots
=
[
'^Main\.main$'
,
'^Paths_.*'
,
'^Paths_.*'
# I'm keeping definitions whose name starts with `test`, in order to
# I'm keeping definitions whose name starts with `test`, in order to
# avoid removing something that might have value, but
we should clarify
# avoid removing something that might have value, but
TODO we should
#
what the purpose of each is, and whether the main source tree is th
e
#
clarify what the purpose of each is, and whether the main source tre
e
# right place for them (rather than, say, in the tests)
#
is the
right place for them (rather than, say, in the tests)
,
'CLI.FilterTermsAndCooc.testCorpus'
,
'CLI.FilterTermsAndCooc.testCorpus'
,
'CLI.FilterTermsAndCooc.testTermList'
,
'CLI.FilterTermsAndCooc.testTermList'
# Useful in the REPL. TODO go through each function in this module ---
# I don't think we need that many variations around `runCmd`?
,
'Gargantext.API.Dev.*'
]
]
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment