learn_linter 1.1.0 → 1.2.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: ba154f1b74ddada6873a18f2ba882bbc26da90ee
4
- data.tar.gz: 18111390edb6629e6c8f5333a2c09981b0da096b
3
+ metadata.gz: 8aa0320e966088c1b214826afff41511f5cbb4ba
4
+ data.tar.gz: 4043017799fd524efd8d9e107af7652c171b6fa5
5
5
  SHA512:
6
- metadata.gz: 96b607d790364f6993179cc198c5d39c76354bd06f8884a0d1e4e18222560b78eb5bd1be2a31b1ddac55a3a748443dc721296505cae1b2d082f3ecbf7125872e
7
- data.tar.gz: fb9d3111b2d5d3015de52532802056fbbb5c44d1142efcf1c22af08793dbf958298e4d6cad53b87cc7c5eff51bb951e5befb0273c950271005e721fb2fe01816
6
+ metadata.gz: 15f0fb239487602bb1da34eb291b20ea8e5e0c280c9f30a44a49c6c3ff28a6e93a6f7d1850cfc93ef30e2b7cb7dae8b34766318ad7c2afc796d27213d6be0964
7
+ data.tar.gz: fd92b17fa5a0c42b547b78266f0b517d8885f0a638959a596fb523a6e8155145f3cf19e1c20653eeaa3f244c64ac3a0797cfc07e9beb8645b9bfc35c3f4962cc
@@ -0,0 +1,17 @@
1
+ class ContributingLinter
2
+
3
+ VALID_FILE = File.open(File.expand_path(File.dirname(__FILE__)) + '/valid_contributing.md')
4
+
5
+ def self.parse_file(file, learn_error)
6
+ directory_file = File.open(file).read
7
+ valid_file = VALID_FILE.read
8
+ if sanitize_whitespace(directory_file) == sanitize_whitespace(valid_file)
9
+ learn_error.contributing_error[:valid_contributing] = true
10
+ learn_error.valid_contributing = {message: "valid contributing", color: :green}
11
+ end
12
+ end
13
+
14
+ def self.sanitize_whitespace(file)
15
+ file.split("\n").delete_if { |l| l.empty? }
16
+ end
17
+ end
@@ -0,0 +1,37 @@
1
+ # Contributing to Learn.co Curriculum
2
+
3
+ We're really exited that you're about to contribute to the [open curriculum](https://learn.co/content-license) on [Learn.co](https://learn.co). If this is your first time contributing, please continue reading to learn how to make the most meaningful and useful impact possible.
4
+
5
+ ## Raising an Issue to Encourage a Contribution
6
+
7
+ If you notice a problem with the curriculum that you believe needs improvement
8
+ but you're unable to make the change yourself, you should raise a Github issue
9
+ containing a clear description of the problem. Include relevant snippets of
10
+ the content and/or screenshots if applicable. Curriculum owners regularly review
11
+ issue lists and your issue will be prioritized and addressed as appropriate.
12
+
13
+ ## Submitting a Pull Request to Suggest an Improvement
14
+
15
+ If you see an opportunity for improvement and can make the change yourself go
16
+ ahead and use a typical git workflow to make it happen:
17
+
18
+ * Fork this curriculum repository
19
+ * Make the change on your fork, with descriptive commits in the standard format
20
+ * Open a Pull Request against this repo
21
+
22
+ A curriculum owner will review your change and approve or comment on it in due
23
+ course.
24
+
25
+ # Why Contribute?
26
+
27
+ Curriculum on Learn is publicly and freely available under Learn's
28
+ [Educational Content License](https://learn.co/content-license). By
29
+ embracing an open-source contribution model, our goal is for the curriculum
30
+ on Learn to become, in time, the best educational content the world has
31
+ ever seen.
32
+
33
+ We need help from the community of Learners to maintain and improve the
34
+ educational content. Everything from fixing typos, to correcting
35
+ out-dated information, to improving exposition, to adding better examples,
36
+ to fixing tests—all contributions to making the curriculum more effective are
37
+ welcome.
@@ -1,3 +1,3 @@
1
1
  class LearnLinter
2
- VERSION = "1.1.0"
2
+ VERSION = "1.2.0"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: learn_linter
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.0
4
+ version: 1.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sophie DeBenedetto
@@ -62,9 +62,11 @@ extra_rdoc_files: []
62
62
  files:
63
63
  - bin/learn-lint
64
64
  - lib/learn_linter.rb
65
+ - lib/learn_linter/contributing_linter.rb
65
66
  - lib/learn_linter/learn_error.rb
66
67
  - lib/learn_linter/license_linter.rb
67
68
  - lib/learn_linter/readme_linter.rb
69
+ - lib/learn_linter/valid_contributing.md
68
70
  - lib/learn_linter/valid_license.md
69
71
  - lib/learn_linter/version.rb
70
72
  - lib/learn_linter/yaml_linter.rb