Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Mirrors
biopet.biopet
Commits
6208b389
Commit
6208b389
authored
Aug 16, 2015
by
Peter van 't Hof
Browse files
Adding simple input files checks
parent
0ae99234
Changes
1
Hide whitespace changes
Inline
Side-by-side
public/biopet-framework/src/main/scala/nl/lumc/sasc/biopet/core/BiopetQScript.scala
View file @
6208b389
...
...
@@ -47,6 +47,10 @@ trait BiopetQScript extends Configurable with GatkLogging {
var
outputFiles
:
Map
[
String
,
File
]
=
Map
()
protected
case
class
InputFile
(
file
:
File
,
md5
:
Option
[
String
]
=
None
)
var
inputFiles
:
List
[
InputFile
]
=
Nil
/** Get implemented from org.broadinstitute.gatk.queue.QScript */
var
qSettings
:
QSettings
...
...
@@ -85,6 +89,11 @@ trait BiopetQScript extends Configurable with GatkLogging {
globalConfig
.
writeReport
(
qSettings
.
runName
,
new
File
(
outputDir
,
".log/"
+
qSettings
.
runName
))
else
BiopetQScript
.
addError
(
"Parent of output dir: '"
+
outputDir
.
getParent
+
"' is not writeable, outputdir can not be created"
)
inputFiles
.
foreach
{
i
=>
if
(!
i
.
file
.
exists
())
BiopetQScript
.
addError
(
s
"Input file does not exist: ${i.file}"
)
if
(!
i
.
file
.
canRead
())
BiopetQScript
.
addError
(
s
"Input file can not be read: ${i.file}"
)
}
reportClass
.
foreach
(
add
(
_
))
BiopetQScript
.
checkErrors
()
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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