trackler 1.0.0 → 1.0.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.travis.yml +7 -0
- data/CHANGELOG.md +9 -1
- data/README.md +10 -0
- data/common/CONTRIBUTING.md +50 -2
- data/common/exercises/alphametics/canonical-data.json +10 -10
- data/common/exercises/markdown/canonical-data.json +4 -4
- data/common/exercises/pov/canonical-data.json +356 -0
- data/lib/trackler/version.rb +1 -1
- data/trackler.gemspec +1 -2
- data/tracks/c/config.json +11 -1
- data/tracks/c/exercises/binary-search/makefile +16 -0
- data/tracks/c/exercises/binary-search/src/example.c +21 -0
- data/tracks/c/exercises/binary-search/src/example.h +8 -0
- data/tracks/c/exercises/binary-search/test/test_binary_search.c +99 -0
- data/tracks/c/exercises/binary-search/test/vendor/unity.c +1300 -0
- data/tracks/c/exercises/binary-search/test/vendor/unity.h +274 -0
- data/tracks/c/exercises/binary-search/test/vendor/unity_internals.h +701 -0
- data/tracks/clojure/config.json +3 -2
- data/tracks/clojure/exercises/bank-account/project.clj +4 -0
- data/tracks/clojure/exercises/bank-account/src/example.clj +17 -0
- data/tracks/clojure/exercises/bank-account/test/bank_account_test.clj +44 -0
- data/tracks/clojure/exercises/isogram/project.clj +4 -0
- data/tracks/clojure/exercises/isogram/src/example.clj +5 -0
- data/tracks/clojure/exercises/isogram/test/isogram_test.clj +17 -0
- data/tracks/csharp/config.json +27 -87
- data/tracks/csharp/exercises/exercises.csproj +265 -1
- data/tracks/csharp/exercises/grep/Example.cs +114 -0
- data/tracks/csharp/exercises/grep/GrepTest.cs +376 -0
- data/tracks/csharp/exercises/paket.references +2 -1
- data/tracks/csharp/exercises/poker/Example.cs +96 -0
- data/tracks/csharp/exercises/poker/PokerTest.cs +171 -0
- data/tracks/csharp/exercises/sgf-parsing/Example.cs +61 -0
- data/tracks/csharp/exercises/sgf-parsing/SgfParsing.cs +13 -0
- data/tracks/csharp/exercises/sgf-parsing/SgfParsingTest.cs +158 -0
- data/tracks/csharp/paket.dependencies +2 -1
- data/tracks/csharp/paket.lock +72 -0
- data/tracks/ecmascript/exercises/simple-cipher/simple-cipher.spec.js +1 -1
- data/tracks/elisp/config.json +6 -1
- data/tracks/elisp/exercises/etl/etl-test.el +90 -0
- data/tracks/elisp/exercises/etl/etl.el +9 -0
- data/tracks/elisp/exercises/etl/example.el +22 -0
- data/tracks/elisp/exercises/nucleotide-count/example.el +19 -0
- data/tracks/elisp/exercises/nucleotide-count/nucleotide-count-test.el +34 -0
- data/tracks/elisp/exercises/nucleotide-count/nucleotide-count.el +9 -0
- data/tracks/elisp/exercises/perfect-numbers/example.el +28 -0
- data/tracks/elisp/exercises/perfect-numbers/perfect-numbers-test.el +24 -0
- data/tracks/elisp/exercises/perfect-numbers/perfect-numbers.el +10 -0
- data/tracks/elisp/exercises/roman-numerals/example.el +36 -0
- data/tracks/elisp/exercises/roman-numerals/roman-numerals-test.el +30 -0
- data/tracks/elisp/exercises/roman-numerals/roman-numerals.el +10 -0
- data/tracks/elisp/exercises/word-count/example.el +18 -0
- data/tracks/elisp/exercises/word-count/word-count-test.el +64 -0
- data/tracks/elisp/exercises/word-count/word-count.el +9 -0
- data/tracks/elixir/README.md +4 -4
- data/tracks/elixir/SETUP.md +3 -3
- data/tracks/elixir/docs/TESTS.md +3 -3
- data/tracks/elixir/exercises/accumulate/accumulate_test.exs +7 -7
- data/tracks/elixir/exercises/acronym/acronym_test.exs +5 -5
- data/tracks/elixir/exercises/allergies/allergies_test.exs +13 -13
- data/tracks/elixir/exercises/anagram/anagram_test.exs +12 -12
- data/tracks/elixir/exercises/atbash-cipher/atbash_cipher_test.exs +9 -9
- data/tracks/elixir/exercises/bank-account/bank_account_test.exs +5 -5
- data/tracks/elixir/exercises/beer-song/beer_song_test.exs +6 -6
- data/tracks/elixir/exercises/binary-search/binary_search_test.exs +7 -7
- data/tracks/elixir/exercises/binary/binary_test.exs +13 -13
- data/tracks/elixir/exercises/bob/bob_test.exs +15 -15
- data/tracks/elixir/exercises/bowling/bowling_test.exs +18 -18
- data/tracks/elixir/exercises/bracket-push/bracket_push_test.exs +12 -12
- data/tracks/elixir/exercises/change/change_test.exs +7 -7
- data/tracks/elixir/exercises/connect/connect_test.exs +9 -9
- data/tracks/elixir/exercises/crypto-square/crypto_square_test.exs +7 -7
- data/tracks/elixir/exercises/custom-set/custom_set_test.exs +11 -11
- data/tracks/elixir/exercises/diamond/diamond_test.exs +4 -4
- data/tracks/elixir/exercises/difference-of-squares/difference_of_squares_test.exs +10 -10
- data/tracks/elixir/exercises/dot-dsl/dot_dsl_test.exs +17 -17
- data/tracks/elixir/exercises/etl/etl_test.exs +5 -5
- data/tracks/elixir/exercises/flatten-array/flatten_array_test.exs +6 -6
- data/tracks/elixir/exercises/forth/forth_test.exs +16 -16
- data/tracks/elixir/exercises/gigasecond/gigasecond_test.exs +5 -5
- data/tracks/elixir/exercises/grade-school/grade_school_test.exs +6 -6
- data/tracks/elixir/exercises/grains/grains_test.exs +9 -9
- data/tracks/elixir/exercises/hamming/hamming_test.exs +6 -6
- data/tracks/elixir/exercises/hello-world/hello_world_test.exs +3 -3
- data/tracks/elixir/exercises/hexadecimal/hexadecimal_test.exs +11 -11
- data/tracks/elixir/exercises/isogram/isogram_test.exs +10 -10
- data/tracks/elixir/exercises/kindergarten-garden/garden_test.exs +7 -7
- data/tracks/elixir/exercises/largest-series-product/largest_series_product_test.exs +17 -17
- data/tracks/elixir/exercises/leap/leap_test.exs +5 -5
- data/tracks/elixir/exercises/list-ops/list_ops_test.exs +26 -26
- data/tracks/elixir/exercises/luhn/luhn_test.exs +7 -7
- data/tracks/elixir/exercises/markdown/markdown_test.exs +10 -10
- data/tracks/elixir/exercises/meetup/meetup_test.exs +92 -92
- data/tracks/elixir/exercises/minesweeper/minesweeper_test.exs +8 -8
- data/tracks/elixir/exercises/nth-prime/nth_prime_test.exs +6 -6
- data/tracks/elixir/exercises/nucleotide-count/example.exs +0 -5
- data/tracks/elixir/exercises/nucleotide-count/nucleotide_count_test.exs +7 -7
- data/tracks/elixir/exercises/palindrome-products/palindrome_products_test.exs +6 -6
- data/tracks/elixir/exercises/pangram/pangram_test.exs +11 -11
- data/tracks/elixir/exercises/parallel-letter-frequency/parallel_letter_frequency_test.exs +10 -10
- data/tracks/elixir/exercises/pascals-triangle/pascals_triangle_test.exs +7 -7
- data/tracks/elixir/exercises/phone-number/phone_number_test.exs +10 -10
- data/tracks/elixir/exercises/prime-factors/prime_factors_test.exs +13 -13
- data/tracks/elixir/exercises/pythagorean-triplet/pythagorean_triplet_test.exs +8 -8
- data/tracks/elixir/exercises/queen-attack/queen_attack_test.exs +16 -16
- data/tracks/elixir/exercises/rail-fence-cipher/rail_fence_cipher_test.exs +13 -13
- data/tracks/elixir/exercises/raindrops/raindrops_test.exs +17 -17
- data/tracks/elixir/exercises/rna-transcription/rna_transcription_test.exs +6 -6
- data/tracks/elixir/exercises/robot-simulator/robot_simulator_test.exs +6 -6
- data/tracks/elixir/exercises/roman-numerals/roman_numerals_test.exs +19 -19
- data/tracks/elixir/exercises/run-length-encoding/rle_test.exs +6 -6
- data/tracks/elixir/exercises/saddle-points/saddle_points_test.exs +11 -11
- data/tracks/elixir/exercises/scrabble-score/scrabble_score_test.exs +9 -9
- data/tracks/elixir/exercises/sieve/sieve_test.exs +3 -3
- data/tracks/elixir/exercises/space-age/space_age_test.exs +9 -9
- data/tracks/elixir/exercises/sublist/sublist_test.exs +20 -20
- data/tracks/elixir/exercises/sum-of-multiples/sum_of_multiples_test.exs +11 -11
- data/tracks/elixir/exercises/test_helper.exs +1 -1
- data/tracks/elixir/exercises/triangle/triangle_test.exs +16 -16
- data/tracks/elixir/exercises/word-count/word_count_test.exs +9 -9
- data/tracks/elixir/exercises/wordy/wordy_test.exs +16 -16
- data/tracks/elixir/exercises/zipper/zipper_test.exs +13 -13
- data/tracks/fsharp/build.fsx +2 -7
- data/tracks/fsharp/config.json +0 -104
- data/tracks/fsharp/exercises/grep/GrepTest.fs +7 -1
- data/tracks/go/config.json +1 -0
- data/tracks/go/exercises/acronym/acronym_test.go +36 -0
- data/tracks/go/exercises/acronym/example.go +21 -0
- data/tracks/go/exercises/palindrome-products/example.go +2 -0
- data/tracks/go/exercises/palindrome-products/palindrome_products_test.go +10 -0
- data/tracks/go/exercises/phone-number/example.go +2 -0
- data/tracks/go/exercises/phone-number/phone_number_test.go +44 -27
- data/tracks/go/exercises/robot-simulator/defs.go +6 -6
- data/tracks/go/exercises/robot-simulator/example.go +22 -22
- data/tracks/go/exercises/robot-simulator/robot_simulator_step2_test.go +28 -28
- data/tracks/go/exercises/robot-simulator/robot_simulator_step3_test.go +75 -76
- data/tracks/go/exercises/robot-simulator/robot_simulator_test.go +10 -4
- data/tracks/haskell/exercises/anagram/HINTS.md +22 -0
- data/tracks/haskell/exercises/anagram/package.yaml +3 -0
- data/tracks/haskell/exercises/anagram/src/Example.hs +10 -7
- data/tracks/haskell/exercises/anagram/test/Tests.hs +9 -3
- data/tracks/haskell/exercises/beer-song/HINTS.md +18 -0
- data/tracks/haskell/exercises/beer-song/src/Beer.hs +301 -3
- data/tracks/haskell/exercises/beer-song/src/Example.hs +5 -3
- data/tracks/haskell/exercises/beer-song/test/Tests.hs +332 -23
- data/tracks/haskell/exercises/crypto-square/src/CryptoSquare.hs +3 -17
- data/tracks/haskell/exercises/crypto-square/src/Example.hs +12 -20
- data/tracks/haskell/exercises/crypto-square/test/Tests.hs +46 -86
- data/tracks/haskell/exercises/leap/HINTS.md +11 -0
- data/tracks/haskell/exercises/leap/src/LeapYear.hs +1 -0
- data/tracks/java/exercises/pangram/src/test/java/PangramTest.java +34 -4
- data/tracks/lua/exercises/pov/pov_spec.lua +0 -13
- data/tracks/mips/docs/ABOUT.md +1 -1
- data/tracks/objective-c/config.json +225 -0
- data/tracks/objective-c/exercises/largest-series-product/LargestSeriesProductExample.h +8 -0
- data/tracks/objective-c/exercises/largest-series-product/LargestSeriesProductExample.m +63 -0
- data/tracks/objective-c/exercises/largest-series-product/LargestSeriesProductTest.m +84 -0
- data/tracks/objective-c/xcodeProject/ObjectiveC.xcodeproj/project.pbxproj +18 -0
- data/tracks/ocaml/.travis-ci.sh +23 -0
- data/tracks/ocaml/.travis.yml +5 -1
- data/tracks/ocaml/Makefile +41 -0
- data/tracks/ocaml/config.json +18 -0
- data/tracks/ocaml/exercises/anagram/Makefile +1 -0
- data/tracks/ocaml/exercises/beer-song/Makefile +1 -0
- data/tracks/ocaml/exercises/beer-song/{beer.mli → beer_song.mli} +0 -0
- data/tracks/ocaml/exercises/beer-song/example.ml +1 -1
- data/tracks/ocaml/exercises/beer-song/test.ml +7 -6
- data/tracks/ocaml/exercises/bob/Makefile +1 -0
- data/tracks/ocaml/exercises/bowling/Makefile +1 -0
- data/tracks/ocaml/exercises/custom-set/Makefile +1 -0
- data/tracks/ocaml/exercises/difference-of-squares/.merlin +5 -0
- data/tracks/ocaml/exercises/difference-of-squares/Makefile +11 -0
- data/tracks/ocaml/exercises/difference-of-squares/difference_of_squares.mli +8 -0
- data/tracks/ocaml/exercises/difference-of-squares/example.ml +21 -0
- data/tracks/ocaml/exercises/difference-of-squares/test.ml +32 -0
- data/tracks/ocaml/exercises/grade-school/Makefile +1 -0
- data/tracks/ocaml/exercises/grade-school/{school.mli → grade_school.mli} +0 -0
- data/tracks/ocaml/exercises/grade-school/test.ml +27 -27
- data/tracks/ocaml/exercises/hamming/Makefile +1 -0
- data/tracks/ocaml/exercises/hangman/Makefile +1 -0
- data/tracks/ocaml/exercises/hello-world/Makefile +1 -1
- data/tracks/ocaml/exercises/hello-world/{hello.ml → hello_world.ml} +0 -0
- data/tracks/ocaml/exercises/hello-world/{hello.mli → hello_world.mli} +0 -0
- data/tracks/ocaml/exercises/hello-world/test.ml +1 -1
- data/tracks/ocaml/exercises/hexadecimal/Makefile +1 -0
- data/tracks/ocaml/exercises/leap/Makefile +1 -1
- data/tracks/ocaml/exercises/list-ops/Makefile +1 -0
- data/tracks/ocaml/exercises/luhn/Makefile +1 -0
- data/tracks/ocaml/exercises/minesweeper/Makefile +1 -0
- data/tracks/ocaml/exercises/nucleotide-count/Makefile +1 -0
- data/tracks/ocaml/exercises/nucleotide-count/{dna.mli → nucleotide_count.mli} +0 -0
- data/tracks/ocaml/exercises/nucleotide-count/test.ml +7 -7
- data/tracks/ocaml/exercises/phone-number/Makefile +1 -0
- data/tracks/ocaml/exercises/phone-number/{phone.mli → phone_number.mli} +0 -0
- data/tracks/ocaml/exercises/phone-number/test.ml +10 -10
- data/tracks/ocaml/exercises/point-mutations/Makefile +8 -0
- data/tracks/ocaml/exercises/point-mutations/example.ml +0 -0
- data/tracks/ocaml/exercises/prime-factors/Makefile +1 -0
- data/tracks/ocaml/exercises/raindrops/.merlin +5 -0
- data/tracks/ocaml/exercises/raindrops/Makefile +11 -0
- data/tracks/ocaml/exercises/raindrops/example.ml +11 -0
- data/tracks/ocaml/exercises/raindrops/raindrops.mli +7 -0
- data/tracks/ocaml/exercises/raindrops/test.ml +48 -0
- data/tracks/ocaml/exercises/rna-transcription/Makefile +1 -0
- data/tracks/ocaml/exercises/rna-transcription/{dna.mli → rna_transcription.mli} +0 -0
- data/tracks/ocaml/exercises/rna-transcription/test.ml +6 -6
- data/tracks/ocaml/exercises/roman-numerals/Makefile +1 -0
- data/tracks/ocaml/exercises/say/.gitignore +1 -0
- data/tracks/ocaml/exercises/say/.merlin +5 -0
- data/tracks/ocaml/exercises/say/Makefile +11 -0
- data/tracks/ocaml/exercises/say/example.ml +52 -0
- data/tracks/ocaml/exercises/say/say.mli +8 -0
- data/tracks/ocaml/exercises/say/test.ml +65 -0
- data/tracks/ocaml/exercises/space-age/Makefile +1 -0
- data/tracks/ocaml/exercises/word-count/Makefile +1 -0
- data/tracks/ocaml/exercises/word-count/example.ml +1 -1
- data/tracks/ocaml/exercises/zipper/HINT.md +5 -6
- data/tracks/ocaml/exercises/zipper/Makefile +1 -0
- data/tracks/ocaml/exercises/zipper/example.ml +2 -2
- data/tracks/ocaml/exercises/zipper/tree.ml +1 -1
- data/tracks/php/config.json +7 -1
- data/tracks/php/exercises/variable-length-quantity/example.php +56 -0
- data/tracks/php/exercises/variable-length-quantity/variable-length-quantity_test.php +149 -0
- data/tracks/python/config.json +1 -1
- data/tracks/ruby/.rubocop.yml +1915 -26
- data/tracks/ruby/bin/generate-acronym +7 -0
- data/tracks/ruby/bin/generate-nth-prime +7 -0
- data/tracks/ruby/config.json +482 -0
- data/tracks/ruby/exercises/acronym/.version +1 -0
- data/tracks/ruby/exercises/acronym/acronym_test.rb +45 -21
- data/tracks/ruby/exercises/acronym/example.rb +1 -1
- data/tracks/ruby/exercises/acronym/example.tt +19 -0
- data/tracks/ruby/exercises/anagram/anagram_test.rb +1 -1
- data/tracks/ruby/exercises/nth-prime/.version +1 -0
- data/tracks/ruby/exercises/nth-prime/example.rb +4 -0
- data/tracks/ruby/exercises/nth-prime/example.tt +23 -0
- data/tracks/ruby/exercises/nth-prime/nth_prime_test.rb +33 -10
- data/tracks/ruby/exercises/raindrops/.version +1 -1
- data/tracks/ruby/exercises/raindrops/example.rb +1 -1
- data/tracks/ruby/exercises/raindrops/raindrops_test.rb +20 -5
- data/tracks/ruby/lib/acronym_cases.rb +19 -0
- data/tracks/ruby/lib/generator.rb +3 -2
- data/tracks/ruby/lib/nth_prime_cases.rb +23 -0
- data/tracks/ruby/lib/raindrop_cases.rb +1 -1
- data/tracks/rust/README.md +1 -1
- data/tracks/scala/exercises/leap/src/test/scala/leap_test.scala +10 -0
- data/tracks/scala/exercises/prime-factors/example.scala +2 -5
- data/tracks/scala/exercises/prime-factors/src/test/scala/primefactors_test.scala +11 -13
- data/tracks/scheme/{anagram → exercises/anagram}/anagram-test.scm +0 -0
- data/tracks/scheme/{anagram → exercises/anagram}/anagram.scm +0 -0
- data/tracks/scheme/{anagram → exercises/anagram}/example.scm +0 -0
- data/tracks/scheme/{bob → exercises/bob}/bob-test.scm +0 -0
- data/tracks/scheme/{bob → exercises/bob}/bob.scm +0 -0
- data/tracks/scheme/{bob → exercises/bob}/example.scm +0 -0
- data/tracks/scheme/{difference-of-squares → exercises/difference-of-squares}/difference-of-squares-test.scm +0 -0
- data/tracks/scheme/{difference-of-squares → exercises/difference-of-squares}/example.scm +0 -0
- data/tracks/scheme/{difference-of-squares → exercises/difference-of-squares}/squares.scm +0 -0
- data/tracks/scheme/{grains → exercises/grains}/example.scm +0 -0
- data/tracks/scheme/{grains → exercises/grains}/grains-test.scm +0 -0
- data/tracks/scheme/{grains → exercises/grains}/grains.scm +0 -0
- data/tracks/scheme/{hamming → exercises/hamming}/example.scm +0 -0
- data/tracks/scheme/{hamming → exercises/hamming}/hamming-test.scm +0 -0
- data/tracks/scheme/{hamming → exercises/hamming}/hamming.scm +0 -0
- data/tracks/scheme/{hello-world → exercises/hello-world}/example.scm +0 -0
- data/tracks/scheme/{hello-world → exercises/hello-world}/hello-world-test.scm +0 -0
- data/tracks/scheme/{hello-world → exercises/hello-world}/hello-world.scm +0 -0
- data/tracks/scheme/{leap → exercises/leap}/example.scm +0 -0
- data/tracks/scheme/{leap → exercises/leap}/leap-test.scm +0 -0
- data/tracks/scheme/{leap → exercises/leap}/leap-year.scm +0 -0
- data/tracks/scheme/{list-ops → exercises/list-ops}/example.scm +0 -0
- data/tracks/scheme/{list-ops → exercises/list-ops}/list-ops-test.scm +0 -0
- data/tracks/scheme/{list-ops → exercises/list-ops}/list-ops.scm +0 -0
- data/tracks/scheme/{nucleotide-count → exercises/nucleotide-count}/example.scm +0 -0
- data/tracks/scheme/{nucleotide-count → exercises/nucleotide-count}/nucleotide-count-test.scm +0 -0
- data/tracks/scheme/{nucleotide-count → exercises/nucleotide-count}/nucleotide-count.scm +0 -0
- data/tracks/scheme/{phone-number → exercises/phone-number}/example.scm +0 -0
- data/tracks/scheme/{phone-number → exercises/phone-number}/phone-number-test.scm +0 -0
- data/tracks/scheme/{phone-number → exercises/phone-number}/phone-number.scm +0 -0
- data/tracks/scheme/{raindrops → exercises/raindrops}/example.scm +0 -0
- data/tracks/scheme/{raindrops → exercises/raindrops}/raindrops-test.scm +0 -0
- data/tracks/scheme/{raindrops → exercises/raindrops}/raindrops.scm +0 -0
- data/tracks/scheme/{rna-transcription → exercises/rna-transcription}/dna.scm +0 -0
- data/tracks/scheme/{rna-transcription → exercises/rna-transcription}/example.scm +0 -0
- data/tracks/scheme/{rna-transcription → exercises/rna-transcription}/rna-transcription-test.scm +0 -0
- data/tracks/scheme/{robot-name → exercises/robot-name}/example.scm +0 -0
- data/tracks/scheme/{robot-name → exercises/robot-name}/robot-name-test.scm +0 -0
- data/tracks/scheme/{robot-name → exercises/robot-name}/robot.scm +0 -0
- metadata +125 -64
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a340d68c1e7151758d18f1d5374de489565c7243
|
4
|
+
data.tar.gz: 97d055586fb1a486a35f63c0a3d56bf0d31efb6e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 787c7c324f3537c1f8ac7ff1549421ad78d63ad9f258bbecb8689fc13c3da4ee8de73c21835280ac9359bdde8f8777bc270dff03fee532c62576e41e243bf45f
|
7
|
+
data.tar.gz: 9bc618ceac0fb5d66caf5874e89f9bbbe398edf6e7a19e7f9de0a26c38fecf2d866020b4a7b2bafb3c8a29e15238cd2e480ff81e44ca1babfa3da8883a4a6a09
|
data/.travis.yml
ADDED
data/CHANGELOG.md
CHANGED
@@ -1,6 +1,14 @@
|
|
1
1
|
# Change log
|
2
2
|
|
3
|
-
The Trackler gem follows [semantic versioning](http://semver.org/).
|
3
|
+
The Trackler gem almost follows [semantic versioning](http://semver.org/).
|
4
|
+
|
5
|
+
We've added a forth level, which tracks content. It gets bumped each time we
|
6
|
+
update the submodules.
|
7
|
+
|
8
|
+
1 . 0 . 0 . 0
|
9
|
+
MAJOR MINOR PATCH CONTENT
|
10
|
+
|
11
|
+
The changelog will not be updated for content updates.
|
4
12
|
|
5
13
|
----------------
|
6
14
|
|
data/README.md
CHANGED
@@ -74,6 +74,16 @@ See CONTRIBUTING.md for details.
|
|
74
74
|
|
75
75
|
This is an extraction from https://github.com/exercism/x-api.
|
76
76
|
|
77
|
+
## Publishing
|
78
|
+
|
79
|
+
Owners of the gem can publish it to rubygems like this:
|
80
|
+
|
81
|
+
```
|
82
|
+
gem build trackler.gemspec
|
83
|
+
gem install --local trackler-$VERSION.gem
|
84
|
+
gem push trackler-$VERSION.gem
|
85
|
+
```
|
86
|
+
|
77
87
|
## License
|
78
88
|
|
79
89
|
The gem is available as open source under the terms of the [MIT License](http://opensource.org/licenses/MIT).
|
data/common/CONTRIBUTING.md
CHANGED
@@ -33,7 +33,9 @@ themselves. There are other guides about contributing to other parts of the Exer
|
|
33
33
|
* [Implementing a Completely New Exercise](#implementing-a-completely-new-exercise)
|
34
34
|
* [Improving Consistency By Extracting Shared Test Data](#improving-consistency-by-extracting-shared-test-data)
|
35
35
|
* [Writing a New Test Suite Generator](#writing-a-new-test-suite-generator)
|
36
|
+
* [Track Anatomy](#track-anatomy)
|
36
37
|
* [Starting a New Track](#starting-a-new-track)
|
38
|
+
* [Beta-Testing a Language Track](#beta-testing-a-language-track)
|
37
39
|
* [Maintaining a Track](#maintaining-a-track)
|
38
40
|
* [Useful Tidbits](#useful-tidbits)
|
39
41
|
* [Exercise Versioning](#exercise-versioning)
|
@@ -193,7 +195,7 @@ test suite](#updating-an-exercise-test-suite).
|
|
193
195
|
If you want to add a new test or change some inputs or outputs, then the change
|
194
196
|
needs to be made in the [exercism/x-common repository](https://github.com/exercism/x-common),
|
195
197
|
not directly to the test suite itself.
|
196
|
-
|
198
|
+
|
197
199
|
Find the JSON file for the problem in question. For example, if you want to change
|
198
200
|
the Clock problem, then look for `exercises/clock/canonical-data.json`.
|
199
201
|
|
@@ -382,6 +384,52 @@ TODO: elaborate.
|
|
382
384
|
|
383
385
|
TODO: elaborate.
|
384
386
|
|
387
|
+
## Track Anatomy
|
388
|
+
|
389
|
+
Each track should have the following structure:
|
390
|
+
|
391
|
+
```bash
|
392
|
+
├── .gitignore
|
393
|
+
├── .travis.yml
|
394
|
+
├── LICENSE
|
395
|
+
├── README.md
|
396
|
+
├── SETUP.md
|
397
|
+
├── bin
|
398
|
+
│ └── fetch-configlet
|
399
|
+
├── config.json
|
400
|
+
├── docs
|
401
|
+
│ ├── ABOUT.md
|
402
|
+
│ ├── INSTALLATION.md
|
403
|
+
│ ├── LEARNING.md
|
404
|
+
│ ├── RESOURCES.md
|
405
|
+
│ └── TESTS.md
|
406
|
+
└── exercises
|
407
|
+
└── hello-world
|
408
|
+
├── hello-world_example.file
|
409
|
+
├── hello-world.file
|
410
|
+
└── hello-world_test.file
|
411
|
+
```
|
412
|
+
|
413
|
+
The example template for a track can be found at [x-template](https://github.com/exercism/x-template).
|
414
|
+
|
415
|
+
* `LICENSE` - The MIT License (MIT)
|
416
|
+
* `README.md` - a thorough explanation of how to contribute to the track.
|
417
|
+
* `SETUP.md` - this should contain any track specific, problem agnostic information that will be included in the README.md of every exercise when fetched. Include information on how to run tests, how to get help, etc.
|
418
|
+
* `bin` - scripts and other files related to running the track's tests, etc.
|
419
|
+
* `config.json` - the track-level configuration. It contains configuration for which exercises (and in which order) are a part of the track, which exercises are deprecated, the track id, name of the language, and the location of the repository. Optionally, it may include a regex to recognize what files are part of the test suite (usually `/test/i`, but sometimes `/spec/i` or other things). If the test pattern is not included, then `/test/i` is assumed.
|
420
|
+
* `docs` - the documentation for the track.These files are served to the exercism.io help site via the x-api. It should contain at minimum:
|
421
|
+
|
422
|
+
- `INSTALLATION.md` - about how to get the track's language set up locally.
|
423
|
+
- `TESTS.md` - how to run the tests for the track's individual exercises.
|
424
|
+
|
425
|
+
Some nice to haves:
|
426
|
+
|
427
|
+
- `ABOUT.md` - a short, friendly blurb about the track's language. What types of problems does it solve really well? What is it typically used for?
|
428
|
+
- `LEARNING.md` - a few notes about where people might want to go to learn the track's language from scratch. These are the the resources you need only when first getting up to speed with a language (tutorials, blog posts, etc.).
|
429
|
+
- `RESOURCES.md` - references and other useful resources. These resources are those that would commonly be used by a developer on an ongoing basis (core language docs, api docs, etc.).
|
430
|
+
|
431
|
+
* `exercises` - all exercises for the track should live in subdirectories of this directory. Each exercise should have a test file, an example file that should pass all tests, and a template file that is a stub to help the user get started with the exercise. The example file should be used for the CI build.
|
432
|
+
|
385
433
|
## Starting a New Track
|
386
434
|
|
387
435
|
If you're interested in adding problems for a language that we don't yet have,
|
@@ -396,7 +444,7 @@ In order to launch the track needs:
|
|
396
444
|
- A handful of people who can check in regularly and provide feedback on solutions.
|
397
445
|
- Documentation in `docs/` for how to get started / run the tests
|
398
446
|
|
399
|
-
Description of what is required for `docs/` can be found in the [
|
447
|
+
Description of what is required for `docs/` can be found in the [Track Anatomy](#track-anatomy).
|
400
448
|
|
401
449
|
Once that is in place, the repository needs to be added as a submodule to
|
402
450
|
[exercism/x-api](https://github.com/exercism/x-api/tree/master/tracks), and
|
@@ -12,16 +12,6 @@
|
|
12
12
|
"puzzle": "SEND + MORE == MONEY",
|
13
13
|
"expected": { "S": 9, "E": 5, "N": 6, "D": 7, "M": 1, "O": 0, "R": 8, "Y": 2 }
|
14
14
|
},
|
15
|
-
{
|
16
|
-
"description": "solve puzzle with multiplication",
|
17
|
-
"puzzle": "IF * DR == DORI",
|
18
|
-
"expected": { "I": 8, "F": 2, "D": 3, "R": 9, "O": 1 }
|
19
|
-
},
|
20
|
-
{
|
21
|
-
"description": "solve puzzle with exponents",
|
22
|
-
"puzzle": "PI * R ^ 2 == AREA",
|
23
|
-
"expected": { "P": 9, "I": 6, "R": 7, "A": 4, "E": 0 }
|
24
|
-
},
|
25
15
|
{
|
26
16
|
"description": "solution must have unique value for each letter",
|
27
17
|
"puzzle": "A == B",
|
@@ -31,6 +21,16 @@
|
|
31
21
|
"description": "leading zero solution is invalid",
|
32
22
|
"puzzle": "ACA + DD == BD",
|
33
23
|
"expected": null
|
24
|
+
},
|
25
|
+
{
|
26
|
+
"description": "solve puzzle with four words",
|
27
|
+
"puzzle": "HE + SEES + THE == LIGHT",
|
28
|
+
"expected": { "E": 4, "G": 2, "H": 5, "I": 0, "L": 1, "S": 9, "T": 7 }
|
29
|
+
},
|
30
|
+
{
|
31
|
+
"description": "solve puzzle with many words",
|
32
|
+
"puzzle": "AND + A + STRONG + OFFENSE + AS + A + GOOD = DEFENSE",
|
33
|
+
"expected": { "A": 5, "D": 3, "E": 4, "F": 7, "G": 8, "N": 0, "O": 2, "R": 1, "S": 6, "T": 9 }
|
34
34
|
}
|
35
35
|
]
|
36
36
|
}
|
@@ -21,17 +21,17 @@
|
|
21
21
|
{
|
22
22
|
"description": "parsing italics",
|
23
23
|
"input": "_This will be italic_",
|
24
|
-
"expected": "<p><
|
24
|
+
"expected": "<p><em>This will be italic</em></p>"
|
25
25
|
},
|
26
26
|
{
|
27
27
|
"description": "parsing bold text",
|
28
28
|
"input": "__This will be bold__",
|
29
|
-
"expected": "<p><
|
29
|
+
"expected": "<p><strong>This will be bold</strong></p>"
|
30
30
|
},
|
31
31
|
{
|
32
32
|
"description": "mixed normal, italics and bold text",
|
33
33
|
"input": "This will _be_ __mixed__",
|
34
|
-
"expected": "<p>This will <
|
34
|
+
"expected": "<p>This will <em>be</em> <strong>mixed</strong></p>"
|
35
35
|
},
|
36
36
|
{
|
37
37
|
"description": "with h1 header level",
|
@@ -56,7 +56,7 @@
|
|
56
56
|
{
|
57
57
|
"description": "With a little bit of everything",
|
58
58
|
"input": "# Header!\n* __Bold Item__\n* _Italic Item_",
|
59
|
-
"expected": "<h1>Header!</h1><ul><li><
|
59
|
+
"expected": "<h1>Header!</h1><ul><li><strong>Bold Item</strong></li><li><em>Italic Item</em></li></ul>"
|
60
60
|
}
|
61
61
|
]
|
62
62
|
}
|
@@ -0,0 +1,356 @@
|
|
1
|
+
{
|
2
|
+
"from_pov": {
|
3
|
+
"description": [
|
4
|
+
"Reroot a tree so that its root is the specified node.",
|
5
|
+
"In this way, the tree is presented from the point of view of the specified node.",
|
6
|
+
"The input trees used here are those in the `trees` section of this file.",
|
7
|
+
"",
|
8
|
+
"If appropriate for your track, you may test that the input tree is not modified.",
|
9
|
+
"",
|
10
|
+
"Note that when rerooting upon a target node that has both parents and children,",
|
11
|
+
"it does not matter whether the former parent comes before or after the former children.",
|
12
|
+
"Please account for this when checking correctness of the resulting trees.",
|
13
|
+
"One suggested method is to only check two things:",
|
14
|
+
"1) The root of the returned tree is the root that was passed in to from_pov.",
|
15
|
+
"2) The sorted edge list of the returned tree is the same as the sorted edge list of the expected tree."
|
16
|
+
],
|
17
|
+
"cases": [
|
18
|
+
{
|
19
|
+
"description": "Results in the same tree if the input tree is a singleton",
|
20
|
+
"tree": "singleton",
|
21
|
+
"from": "x",
|
22
|
+
"expected": {
|
23
|
+
"label": "x"
|
24
|
+
}
|
25
|
+
},
|
26
|
+
{
|
27
|
+
"description": "Can reroot a tree with a parent and one sibling",
|
28
|
+
"tree": "simple",
|
29
|
+
"from": "x",
|
30
|
+
"expected": {
|
31
|
+
"label": "x",
|
32
|
+
"children": [
|
33
|
+
{
|
34
|
+
"label": "parent",
|
35
|
+
"children": [
|
36
|
+
{
|
37
|
+
"label": "sibling"
|
38
|
+
}
|
39
|
+
]
|
40
|
+
}
|
41
|
+
]
|
42
|
+
}
|
43
|
+
},
|
44
|
+
{
|
45
|
+
"description": "Can reroot a tree with a parent and many siblings",
|
46
|
+
"tree": "large_flat",
|
47
|
+
"from": "x",
|
48
|
+
"expected": {
|
49
|
+
"label": "x",
|
50
|
+
"children": [
|
51
|
+
{
|
52
|
+
"label": "parent",
|
53
|
+
"children": [
|
54
|
+
{
|
55
|
+
"label": "a"
|
56
|
+
},
|
57
|
+
{
|
58
|
+
"label": "b"
|
59
|
+
},
|
60
|
+
{
|
61
|
+
"label": "c"
|
62
|
+
}
|
63
|
+
]
|
64
|
+
}
|
65
|
+
]
|
66
|
+
}
|
67
|
+
},
|
68
|
+
{
|
69
|
+
"description": "Can reroot a tree with new root deeply nested in tree",
|
70
|
+
"tree": "deeply_nested",
|
71
|
+
"from": "x",
|
72
|
+
"expected": {
|
73
|
+
"label": "x",
|
74
|
+
"children": [
|
75
|
+
{
|
76
|
+
"label": "level-3",
|
77
|
+
"children": [
|
78
|
+
{
|
79
|
+
"label": "level-2",
|
80
|
+
"children": [
|
81
|
+
{
|
82
|
+
"label": "level-1",
|
83
|
+
"children": [
|
84
|
+
{
|
85
|
+
"label": "level-0"
|
86
|
+
}
|
87
|
+
]
|
88
|
+
}
|
89
|
+
]
|
90
|
+
}
|
91
|
+
]
|
92
|
+
}
|
93
|
+
]
|
94
|
+
}
|
95
|
+
},
|
96
|
+
{
|
97
|
+
"description": "Moves children of the new root to same level as former parent",
|
98
|
+
"tree": "kids",
|
99
|
+
"from": "x",
|
100
|
+
"expected": {
|
101
|
+
"label": "x",
|
102
|
+
"children": [
|
103
|
+
{
|
104
|
+
"label": "kid-0"
|
105
|
+
},
|
106
|
+
{
|
107
|
+
"label": "kid-1"
|
108
|
+
},
|
109
|
+
{
|
110
|
+
"label": "parent"
|
111
|
+
}
|
112
|
+
]
|
113
|
+
}
|
114
|
+
},
|
115
|
+
{
|
116
|
+
"description": "Can reroot a complex tree with cousins",
|
117
|
+
"tree": "cousins",
|
118
|
+
"from": "x",
|
119
|
+
"expected": {
|
120
|
+
"label": "x",
|
121
|
+
"children": [
|
122
|
+
{
|
123
|
+
"label": "kid-1"
|
124
|
+
},
|
125
|
+
{
|
126
|
+
"label": "kid-0"
|
127
|
+
},
|
128
|
+
{
|
129
|
+
"label": "parent",
|
130
|
+
"children": [
|
131
|
+
{
|
132
|
+
"label": "sibling-0"
|
133
|
+
},
|
134
|
+
{
|
135
|
+
"label": "sibling-1"
|
136
|
+
},
|
137
|
+
{
|
138
|
+
"label": "grandparent",
|
139
|
+
"children": [
|
140
|
+
{
|
141
|
+
"label": "uncle",
|
142
|
+
"children": [
|
143
|
+
{
|
144
|
+
"label": "cousin-0"
|
145
|
+
},
|
146
|
+
{
|
147
|
+
"label": "cousin-1"
|
148
|
+
}
|
149
|
+
]
|
150
|
+
}
|
151
|
+
]
|
152
|
+
}
|
153
|
+
]
|
154
|
+
}
|
155
|
+
]
|
156
|
+
}
|
157
|
+
},
|
158
|
+
{
|
159
|
+
"description": "Errors if target does not exist in a singleton tree",
|
160
|
+
"tree": "singleton",
|
161
|
+
"from": "nonexistent",
|
162
|
+
"expected": null
|
163
|
+
},
|
164
|
+
{
|
165
|
+
"description": "Errors if target does not exist in a large tree",
|
166
|
+
"tree": "cousins",
|
167
|
+
"from": "nonexistent",
|
168
|
+
"expected": null
|
169
|
+
}
|
170
|
+
]
|
171
|
+
},
|
172
|
+
"path_to": {
|
173
|
+
"description": [
|
174
|
+
"Given two nodes, find the path between them.",
|
175
|
+
"A typical implementation would first reroot the tree on one of the two nodes.",
|
176
|
+
"",
|
177
|
+
"If appropriate for your track, you may test that the input tree is not modified.",
|
178
|
+
"",
|
179
|
+
"The trees used here are those in the `trees` section of this file."
|
180
|
+
],
|
181
|
+
"cases": [
|
182
|
+
{
|
183
|
+
"description": "Can find path to parent",
|
184
|
+
"from": "x",
|
185
|
+
"to": "parent",
|
186
|
+
"tree": "simple",
|
187
|
+
"expected": [
|
188
|
+
"x",
|
189
|
+
"parent"
|
190
|
+
]
|
191
|
+
},
|
192
|
+
{
|
193
|
+
"description": "Can find path to sibling",
|
194
|
+
"from": "x",
|
195
|
+
"to": "b",
|
196
|
+
"tree": "large_flat",
|
197
|
+
"expected": [
|
198
|
+
"x",
|
199
|
+
"parent",
|
200
|
+
"b"
|
201
|
+
]
|
202
|
+
},
|
203
|
+
{
|
204
|
+
"description": "Can find path to cousin",
|
205
|
+
"from": "x",
|
206
|
+
"to": "cousin-1",
|
207
|
+
"tree": "cousins",
|
208
|
+
"expected": [
|
209
|
+
"x",
|
210
|
+
"parent",
|
211
|
+
"grandparent",
|
212
|
+
"uncle",
|
213
|
+
"cousin-1"
|
214
|
+
]
|
215
|
+
},
|
216
|
+
{
|
217
|
+
"description": "Can find path from nodes other than x",
|
218
|
+
"from": "kid-1",
|
219
|
+
"to": "cousin-0",
|
220
|
+
"tree": "cousins",
|
221
|
+
"expected": [
|
222
|
+
"kid-1",
|
223
|
+
"x",
|
224
|
+
"parent",
|
225
|
+
"grandparent",
|
226
|
+
"uncle",
|
227
|
+
"cousin-0"
|
228
|
+
]
|
229
|
+
},
|
230
|
+
{
|
231
|
+
"description": "Errors if destination does not exist",
|
232
|
+
"from": "x",
|
233
|
+
"to": "nonexistent",
|
234
|
+
"tree": "cousins",
|
235
|
+
"expected": null
|
236
|
+
},
|
237
|
+
{
|
238
|
+
"description": "Errors if source does not exist",
|
239
|
+
"from": "nonexistent",
|
240
|
+
"to": "x",
|
241
|
+
"tree": "cousins",
|
242
|
+
"expected": null
|
243
|
+
}
|
244
|
+
]
|
245
|
+
},
|
246
|
+
"trees": {
|
247
|
+
"singleton": {
|
248
|
+
"label": "x"
|
249
|
+
},
|
250
|
+
"simple": {
|
251
|
+
"label": "parent",
|
252
|
+
"children": [
|
253
|
+
{
|
254
|
+
"label": "x"
|
255
|
+
},
|
256
|
+
{
|
257
|
+
"label": "sibling"
|
258
|
+
}
|
259
|
+
]
|
260
|
+
},
|
261
|
+
"large_flat": {
|
262
|
+
"label": "parent",
|
263
|
+
"children": [
|
264
|
+
{
|
265
|
+
"label": "a"
|
266
|
+
},
|
267
|
+
{
|
268
|
+
"label": "x"
|
269
|
+
},
|
270
|
+
{
|
271
|
+
"label": "b"
|
272
|
+
},
|
273
|
+
{
|
274
|
+
"label": "c"
|
275
|
+
}
|
276
|
+
]
|
277
|
+
},
|
278
|
+
"deeply_nested": {
|
279
|
+
"label": "level-0",
|
280
|
+
"children": [
|
281
|
+
{
|
282
|
+
"label": "level-1",
|
283
|
+
"children": [
|
284
|
+
{
|
285
|
+
"label": "level-2",
|
286
|
+
"children": [
|
287
|
+
{
|
288
|
+
"label": "level-3",
|
289
|
+
"children": [
|
290
|
+
{
|
291
|
+
"label": "x"
|
292
|
+
}
|
293
|
+
]
|
294
|
+
}
|
295
|
+
]
|
296
|
+
}
|
297
|
+
]
|
298
|
+
}
|
299
|
+
]
|
300
|
+
},
|
301
|
+
"kids": {
|
302
|
+
"label": "parent",
|
303
|
+
"children": [
|
304
|
+
{
|
305
|
+
"label": "x",
|
306
|
+
"children": [
|
307
|
+
{
|
308
|
+
"label": "kid-0"
|
309
|
+
},
|
310
|
+
{
|
311
|
+
"label": "kid-1"
|
312
|
+
}
|
313
|
+
]
|
314
|
+
}
|
315
|
+
]
|
316
|
+
},
|
317
|
+
"cousins": {
|
318
|
+
"label": "grandparent",
|
319
|
+
"children": [
|
320
|
+
{
|
321
|
+
"label": "parent",
|
322
|
+
"children": [
|
323
|
+
{
|
324
|
+
"label": "x",
|
325
|
+
"children": [
|
326
|
+
{
|
327
|
+
"label": "kid-0"
|
328
|
+
},
|
329
|
+
{
|
330
|
+
"label": "kid-1"
|
331
|
+
}
|
332
|
+
]
|
333
|
+
},
|
334
|
+
{
|
335
|
+
"label": "sibling-0"
|
336
|
+
},
|
337
|
+
{
|
338
|
+
"label": "sibling-1"
|
339
|
+
}
|
340
|
+
]
|
341
|
+
},
|
342
|
+
{
|
343
|
+
"label": "uncle",
|
344
|
+
"children": [
|
345
|
+
{
|
346
|
+
"label": "cousin-0"
|
347
|
+
},
|
348
|
+
{
|
349
|
+
"label": "cousin-1"
|
350
|
+
}
|
351
|
+
]
|
352
|
+
}
|
353
|
+
]
|
354
|
+
}
|
355
|
+
}
|
356
|
+
}
|