tmspzz / danger-hlint Goto Github PK
View Code? Open in Web Editor NEWA Danger plugin for Hlint - https://rubygems.org/gems/danger-hlint
License: MIT License
A Danger plugin for Hlint - https://rubygems.org/gems/danger-hlint
License: MIT License
I'm struggling with trying to get hlint
output as a comment on my PR. Here's the Dangerfile
:
# Sometimes it's a README fix, or something like that - which isn't relevant for
# including in a project's CHANGELOG for example
declared_trivial = github.pr_title.include? "#trivial"
# Make it more obvious that a PR is a work in progress and shouldn't be merged yet
warn("PR is classed as Work in Progress") if github.pr_title.include? "[WIP]"
# Warn when there is a big PR
warn("Big PR") if git.lines_of_code > 500
# Don't let testing shortcuts get into master by accident
fail("fdescribe left in tests") if `grep -r fdescribe specs/ `.length > 1
fail("fit left in tests") if `grep -r fit specs/ `.length > 1
# get all affected files by the changes in the current diff
affected_files = git.added_files + git.modified_files
# limit files to .hs files
haskell_files = affected_files.select { |file| file.end_with?('.hs') }
# run hlint on the files and comment inline in the PR
hlint.lint haskell_files
The only thing I've been able to get as a comment, is the following...
...the hlint output seems to be missing. I've made sure that hlint
has some output by executing the following command locally:
bundle exec danger pr [PR-URL]
We're currently trying to enable the plugin for a project in Gitlab. The inline comments there seem to be rendered quite unexpectedly - there're some closing </tr>
tags appearing as a plain text in a comment's resultant html.
Danger system's comment templates seem to be the same for both Gitlab and Github - do you have any ideas why the above happens? And does the plugin support Gitlab?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.