-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add a warning for unpinned nf-schema versions
- Loading branch information
Showing
1 changed file
with
19 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -118,6 +118,25 @@ class SchemaValidator extends PluginExtensionPoint { | |
protected void init(Session session) { | ||
this.session = session | ||
this.config = new ValidationConfig(session.config.navigate('validation') as Map) | ||
def plugins = session.config.navigate("plugins") as ArrayList | ||
if(plugins.contains("nf-schema")) { | ||
log.warn(""" | ||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! | ||
! ! | ||
! WARNING! ! | ||
! ! | ||
! You just entered the danger zone! ! | ||
! Please pin the nf-schema version in your config! ! | ||
! Not pinning your version can't guarantee the reproducibility ! | ||
! and the functionality of this pipeline in the future ! | ||
! ! | ||
! plugins { ! | ||
! id "[email protected]" ! | ||
! } ! | ||
! ! | ||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! | ||
""") | ||
} | ||
} | ||
|
||
boolean hasErrors() { errors.size()>0 } | ||
|