Skip to content

Commit

Permalink
Merge pull request licensee#259 from andrew/elm
Browse files Browse the repository at this point in the history
Allow detection of license in elm-package.json
  • Loading branch information
benbalter authored Jan 5, 2018
2 parents a99b08e + 3752e27 commit 3a105b0
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
13 changes: 7 additions & 6 deletions lib/licensee/project_files/package_manager_file.rb
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,13 @@ class PackageManagerFile < Licensee::ProjectFiles::ProjectFile
}.freeze

FILENAMES_SCORES = {
'package.json' => 1.0,
'LICENSE.spdx' => 1.0,
'Cargo.toml' => 1.0,
'DESCRIPTION' => 0.9,
'dist.ini' => 0.8,
'bower.json' => 0.75
'package.json' => 1.0,
'LICENSE.spdx' => 1.0,
'Cargo.toml' => 1.0,
'DESCRIPTION' => 0.9,
'dist.ini' => 0.8,
'bower.json' => 0.75,
'elm-package.json' => 0.7
}.freeze

def possible_matchers
Expand Down
1 change: 1 addition & 0 deletions spec/licensee/project_files/package_info_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
'DESCRIPTION' => 0.9,
'dist.ini' => 0.8,
'bower.json' => 0.75,
'elm-package.json' => 0.70,
'README.md' => 0.0
}.each do |filename, expected_score|
context "a file named #{filename}" do
Expand Down

0 comments on commit 3a105b0

Please sign in to comment.