Skip to content

Commit e302608

Browse files
author
Daniel Mita
authored
Use raku extensions (#394)
1 parent 3c778ba commit e302608

File tree

207 files changed

+204
-233
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

207 files changed

+204
-233
lines changed

.proverc

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
--exec perl6
2-
--ext t6
1+
--exec raku
2+
--ext rakutest

.travis.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,5 +12,5 @@ script:
1212
&& prove6
1313
--jobs 2
1414
exercises/*/.meta/solutions/
15-
&& prove t/*.t6
15+
&& prove t/*.rakutest
1616
--directives'

README.md

+2-2

appveyor.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ for:
1313
before_test:
1414
- bin/fetch-configlet
1515
test_script:
16-
- bin/configlet lint . --track-id=perl6
16+
- bin/configlet lint . --track-id=raku
1717
- docker run
1818
--mount "type=bind,src=$(pwd),dst=/exercism"
1919
rakudo-star /bin/bash -c 'cd /exercism
@@ -22,7 +22,7 @@ for:
2222
&& prove6
2323
--jobs 2
2424
exercises/*/.meta/solutions/
25-
&& prove t/*.t6
25+
&& prove t/*.rakutest
2626
--directives'
2727
- matrix:
2828
only:

bin/README.md

+5-5

bin/exercise-gen.p6 bin/exercise-gen.raku

+5-6
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
#!/usr/bin/env perl6
2-
use v6;
1+
#!/usr/bin/env raku
32
use YAMLish;
43
use nqp;
54
use lib (my $base-dir = $?FILE.IO.resolve.parent.parent).add('lib');
@@ -61,21 +60,21 @@ sub generate ($exercise) {
6160
print "Generating $exercise... ";
6261

6362
given Exercism::Generator.new: :$exercise, data => load-yaml $yaml-file.absolute.IO.slurp {
64-
my $testfile = $exercise-dir.add("$exercise.t6");
63+
my $testfile = $exercise-dir.add("$exercise.rakutest");
6564
$testfile.spurt: .test;
6665
$testfile.chmod: 0o755;
6766

68-
$exercise-dir.add("{.data<exercise>}.pm6").spurt: .stub;
67+
$exercise-dir.add("{.data<exercise>}.rakumod").spurt: .stub;
6968

7069
$exercise-dir.add('.meta/solutions').mkdir;
7170
for .examples.pairs -> $example {
7271
if $example.key ~~ 'base' {
73-
$exercise-dir.add(".meta/solutions/{.data<exercise>}.pm6").spurt: $example.value;
72+
$exercise-dir.add(".meta/solutions/{.data<exercise>}.rakumod").spurt: $example.value;
7473
try nqp::symlink("../../$_", ~$exercise-dir.add(".meta/solutions/$_")) given $testfile.basename;
7574
}
7675
else {
7776
$exercise-dir.add(".meta/solutions/{$example.key}").mkdir;
78-
$exercise-dir.add(".meta/solutions/{$example.key}/{.data<exercise>}.pm6").spurt: $example.value;
77+
$exercise-dir.add(".meta/solutions/{$example.key}/{.data<exercise>}.rakumod").spurt: $example.value;
7978
try nqp::symlink("../../../$_", ~$exercise-dir.add(".meta/solutions/{$example.key}/$_")) given $testfile.basename;
8079
}
8180
}

config.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
"active": true,
44
"blurb": "Raku is a production ready new emerging language that is highly expressive, feature-packed and optimized for fun.",
55
"checklist_issue": 30,
6-
"solution_pattern": "\\.meta/solutions/.+\\.pm6$",
7-
"test_pattern": ".*\\.t6$",
6+
"solution_pattern": "\\.meta/solutions/.+\\.rakumod$",
7+
"test_pattern": ".*\\.rakutest$",
88
"exercises": [
99
{
1010
"slug": "hello-world",

config/exercise_readme.go.tmpl

+3-3
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,10 @@ examples if you get stuck.
1313
## Running the tests
1414

1515
There is a test suite and module included with the exercise.
16-
The test suite (a file with the extension `.t6`) will attempt to run routines
17-
from the module (a file with the extension `.pm6`).
16+
The test suite (a file with the extension `.rakutest`) will attempt to run routines
17+
from the module (a file with the extension `.rakumod`).
1818
Add/modify routines in the module so that the tests will pass! You can view the
19-
test data by executing the command `perl6 --doc *.t6` (\* being the name of the
19+
test data by executing the command `raku --doc *.rakutest` (\* being the name of the
2020
test suite), and run the test suite for the exercise by executing the command
2121
`prove6 .` in the exercise directory.
2222
{{ with .Spec.Credits }}

docs/LEARNING.md

+1-1

docs/TESTS.md

+11-11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
../../accumulate.rakutest

exercises/accumulate/.meta/solutions/accumulate.t6

-1
This file was deleted.
File renamed without changes.

exercises/accumulate/README.md

+3-3

exercises/accumulate/accumulate.t6 exercises/accumulate/accumulate.rakutest

+1-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
#!/usr/bin/env perl6
2-
use v6;
1+
#!/usr/bin/env raku
32
use Test;
43
use lib $?FILE.IO.dirname;
54
use Accumulate;
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
../../acronym.rakutest

exercises/acronym/.meta/solutions/acronym.t6

-1
This file was deleted.
File renamed without changes.

exercises/acronym/README.md

+3-3

exercises/acronym/acronym.t6 exercises/acronym/acronym.rakutest

+1-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
#!/usr/bin/env perl6
2-
use v6;
1+
#!/usr/bin/env raku
32
use Test;
43
use JSON::Fast;
54
use lib $?FILE.IO.dirname;
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
../../all-your-base.rakutest

exercises/all-your-base/.meta/solutions/all-your-base.t6

-1
This file was deleted.

exercises/all-your-base/README.md

+3-3

exercises/all-your-base/all-your-base.t6 exercises/all-your-base/all-your-base.rakutest

+1-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
#!/usr/bin/env perl6
2-
use v6;
1+
#!/usr/bin/env raku
32
use Test;
43
use JSON::Fast;
54
use lib $?FILE.IO.dirname;
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
../../allergies.rakutest

exercises/allergies/.meta/solutions/allergies.t6

-1
This file was deleted.
File renamed without changes.

exercises/allergies/README.md

+3-3

exercises/allergies/allergies.t6 exercises/allergies/allergies.rakutest

+1-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
#!/usr/bin/env perl6
2-
use v6;
1+
#!/usr/bin/env raku
32
use Test;
43
use JSON::Fast;
54
use lib $?FILE.IO.dirname;
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
../../anagram.rakutest

exercises/anagram/.meta/solutions/anagram.t6

-1
This file was deleted.
File renamed without changes.

exercises/anagram/README.md

+3-3

exercises/anagram/anagram.t6 exercises/anagram/anagram.rakutest

+1-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
#!/usr/bin/env perl6
2-
use v6;
1+
#!/usr/bin/env raku
32
use Test;
43
use JSON::Fast;
54
use lib $?FILE.IO.dirname;
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
../../atbash-cipher.rakutest

exercises/atbash-cipher/.meta/solutions/atbash-cipher.t6

-1
This file was deleted.

exercises/atbash-cipher/README.md

+3-3

exercises/atbash-cipher/atbash-cipher.t6 exercises/atbash-cipher/atbash-cipher.rakutest

+1-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
#!/usr/bin/env perl6
2-
use v6;
1+
#!/usr/bin/env raku
32
use Test;
43
use JSON::Fast;
54
use lib $?FILE.IO.dirname;
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
../../binary.rakutest

exercises/binary/.meta/solutions/binary.t6

-1
This file was deleted.
File renamed without changes.

exercises/binary/README.md

+3-3

exercises/binary/binary.t6 exercises/binary/binary.rakutest

+1-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
#!/usr/bin/env perl6
2-
use v6;
1+
#!/usr/bin/env raku
32
use Test;
43
use lib $?FILE.IO.dirname;
54
use Binary;
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
../../bob.rakutest

0 commit comments

Comments
 (0)