Skip to content

Commit 33dcd0a

Browse files
committed
convert to Dist::Zilla
1 parent 372e249 commit 33dcd0a

18 files changed

+1228
-190
lines changed

.editorconfig

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
root = true
2+
3+
[*]
4+
indent_style = space
5+
indent_size = 4
6+
7+
end_of_line = lf
8+
charset = utf-8
9+
10+
trim_trailing_whitespace = true
11+
insert_final_newline = true
12+
13+
[*.{yml,yaml}]
14+
indent_size = 2
15+
quote_type = single
16+
17+
[Changes]
18+
indent_size = 2

.github/workflows/test.yml

+177
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,177 @@
1+
name: Test
2+
on:
3+
push: ~
4+
pull_request: ~
5+
6+
jobs:
7+
perl-versions:
8+
runs-on: ubuntu-latest
9+
name: Calculate Perl Versions
10+
outputs:
11+
versions: ${{ steps.perl-versions.outputs.perl-versions }}
12+
steps:
13+
- uses: actions/checkout@v4
14+
- id: perl-versions
15+
uses: perl-actions/perl-versions@v1
16+
with:
17+
since-perl: v5.14
18+
with-devel: true
19+
20+
build:
21+
runs-on: ubuntu-latest
22+
steps:
23+
- uses: actions/checkout@v4
24+
- uses: actions/cache@v4
25+
with:
26+
path: ~/.perl-cpm
27+
key: cpm-${{ runner.os }}
28+
- name: Setup local::lib
29+
run: |
30+
echo "$RUNNER_TEMP/perl5/bin" >> "$GITHUB_PATH"
31+
echo "PERL5LIB=$RUNNER_TEMP/perl5/lib/perl5:$PERL5LIB" >> "$GITHUB_ENV"
32+
echo "PERL_MB_OPT=--install_base $RUNNER_TEMP/perl5" >> "$GITHUB_ENV"
33+
echo "PERL_MM_OPT=INSTALL_BASE=$RUNNER_TEMP/perl5" >> "$GITHUB_ENV"
34+
- name: Extract Dist::Zilla dependencies
35+
id: authordeps
36+
uses: perl-actions/get-prereqs@v1
37+
with:
38+
sources: dist.ini
39+
phases: author
40+
- name: Install authordeps
41+
uses: perl-actions/install-with-cpm@v1
42+
with:
43+
sudo: false
44+
install: ${{ steps.authordeps.outputs.prereqs }}
45+
- name: Build
46+
id: build
47+
run: |
48+
DZIL_COLOR=1 dzil build --no-tgz | tee "/tmp/dzil-build.log"
49+
echo build="$(grep --only-matching 'built in .*' "/tmp/dzil-build.log" | tail -1 | cut -c10-)" >> "$GITHUB_OUTPUT"
50+
- name: Upload build
51+
uses: actions/upload-artifact@v4
52+
with:
53+
name: ${{ steps.build.outputs.build }}
54+
path: ${{ steps.build.outputs.build }}
55+
include-hidden-files: true
56+
outputs:
57+
name: ${{ steps.build.outputs.build }}
58+
59+
test:
60+
needs:
61+
- perl-versions
62+
- build
63+
64+
strategy:
65+
fail-fast: false
66+
matrix:
67+
perl-version: ${{ fromJson(needs.perl-versions.outputs.versions) }}
68+
69+
runs-on: ubuntu-latest
70+
container:
71+
image: perl:${{ matrix.perl-version }}-buster
72+
73+
env:
74+
AUTOMATED_TESTING: 1
75+
PERL_USE_UNSAFE_INC: 0
76+
77+
steps:
78+
- name: Download build
79+
uses: actions/download-artifact@v4
80+
with:
81+
name: ${{ needs.build.outputs.name }}
82+
- uses: actions/cache@v4
83+
with:
84+
path: ~/.perl-cpm
85+
key: cpm-perl:${{ matrix.perl-version }}-buster
86+
- name: Setup local::lib
87+
run: |
88+
echo "$RUNNER_TEMP/perl5/bin" >> "$GITHUB_PATH"
89+
echo "PERL5LIB=$RUNNER_TEMP/perl5/lib/perl5:$PERL5LIB" >> "$GITHUB_ENV"
90+
echo "PERL_MB_OPT=--install_base $RUNNER_TEMP/perl5" >> "$GITHUB_ENV"
91+
echo "PERL_MM_OPT=INSTALL_BASE=$RUNNER_TEMP/perl5" >> "$GITHUB_ENV"
92+
- name: Extract configure dependecies
93+
id: configure
94+
uses: perl-actions/get-prereqs@v1
95+
with:
96+
phases: configure
97+
- name: Install configure deps
98+
uses: perl-actions/install-with-cpm@v1
99+
with:
100+
sudo: false
101+
install: ${{ steps.configure.outputs.prereqs }}
102+
- name: Run Makefile.PL
103+
run: perl Makefile.PL
104+
- name: Extract dependecies
105+
id: prereqs
106+
uses: perl-actions/get-prereqs@v1
107+
with:
108+
phases: build test runtime
109+
relationships: requires recommends suggests
110+
- name: Install deps
111+
uses: perl-actions/install-with-cpm@v1
112+
with:
113+
sudo: false
114+
install: ${{ steps.prereqs.outputs.prereqs }}
115+
- name: Run the tests
116+
run: make test
117+
env:
118+
AUTHOR_TESTING: 1
119+
120+
test-xt:
121+
needs:
122+
- perl-versions
123+
- build
124+
125+
runs-on: ubuntu-latest
126+
container:
127+
image: perl:5.36-buster
128+
129+
env:
130+
AUTOMATED_TESTING: 1
131+
132+
steps:
133+
- name: Download build
134+
uses: actions/download-artifact@v4
135+
with:
136+
name: ${{ needs.build.outputs.name }}
137+
- uses: actions/cache@v4
138+
with:
139+
path: ~/.perl-cpm
140+
key: cpm-perl:5.36-buster
141+
- name: Setup local::lib
142+
run: |
143+
echo "$RUNNER_TEMP/perl5/bin" >> "$GITHUB_PATH"
144+
echo "PERL5LIB=$RUNNER_TEMP/perl5/lib/perl5:$PERL5LIB" >> "$GITHUB_ENV"
145+
echo "PERL_MB_OPT=--install_base $RUNNER_TEMP/perl5" >> "$GITHUB_ENV"
146+
echo "PERL_MM_OPT=INSTALL_BASE=$RUNNER_TEMP/perl5" >> "$GITHUB_ENV"
147+
- name: Extract configure dependecies
148+
id: configure
149+
uses: perl-actions/get-prereqs@v1
150+
with:
151+
phases: configure
152+
- name: Install configure deps
153+
uses: perl-actions/install-with-cpm@v1
154+
with:
155+
sudo: false
156+
install: ${{ steps.configure.outputs.prereqs }}
157+
- name: Run Makefile.PL
158+
run: perl Makefile.PL
159+
- name: Extract dependecies
160+
id: prereqs
161+
uses: perl-actions/get-prereqs@v1
162+
with:
163+
phases: build test runtime develop
164+
relationships: requires recommends suggests
165+
- name: Install deps
166+
uses: perl-actions/install-with-cpm@v1
167+
with:
168+
sudo: false
169+
install: ${{ steps.prereqs.outputs.prereqs }}
170+
- name: Run the xt tests
171+
run: prove -l xt
172+
env:
173+
AUTHOR_TESTING: 1
174+
- name: Run the xt/author tests
175+
run: prove -lr xt/author
176+
env:
177+
AUTHOR_TESTING: 1

.gitignore

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
/MANIFEST.bak
2+
/Makefile.old
3+
/Makefile
4+
/blib/
5+
/pm_to_blib
6+
/MYMETA.json
7+
/MYMETA.yml
8+
/cover_db/
9+
/MYMETA.json.lock
10+
/MANIFEST
11+
/.build/
12+
/Catalyst-Action-RenderView-*.tar.gz
13+
/Catalyst-Action-RenderView-*/

.perlcriticrc

+81
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,81 @@
1+
severity = 1
2+
verbose = 9
3+
only = 1
4+
5+
[BuiltinFunctions::ProhibitLvalueSubstr]
6+
[BuiltinFunctions::ProhibitShiftRef]
7+
[BuiltinFunctions::ProhibitSleepViaSelect]
8+
[BuiltinFunctions::ProhibitStringyEval]
9+
[BuiltinFunctions::ProhibitUniversalCan]
10+
[BuiltinFunctions::ProhibitUniversalIsa]
11+
[BuiltinFunctions::ProhibitVoidGrep]
12+
[BuiltinFunctions::ProhibitVoidMap]
13+
[BuiltinFunctions::RequireGlobFunction]
14+
[BuiltinFunctions::RequireSimpleSortBlock]
15+
[ClassHierarchies::ProhibitOneArgBless]
16+
[CodeLayout::ProhibitHardTabs]
17+
[CodeLayout::RequireConsistentNewlines]
18+
[ControlStructures::ProhibitCascadingIfElse]
19+
[ControlStructures::ProhibitDeepNests]
20+
[ControlStructures::ProhibitLabelsWithSpecialBlockNames]
21+
[ControlStructures::ProhibitMutatingListFunctions]
22+
[ControlStructures::ProhibitNegativeExpressionsInUnlessAndUntilConditions]
23+
[ControlStructures::ProhibitUnreachableCode]
24+
[ControlStructures::ProhibitYadaOperator]
25+
[ErrorHandling::RequireCheckingReturnValueOfEval]
26+
[InputOutput::ProhibitBacktickOperators]
27+
[InputOutput::ProhibitBarewordFileHandles]
28+
[InputOutput::ProhibitExplicitStdin]
29+
[InputOutput::ProhibitInteractiveTest]
30+
[InputOutput::ProhibitJoinedReadline]
31+
[InputOutput::ProhibitOneArgSelect]
32+
[InputOutput::ProhibitReadlineInForLoop]
33+
[InputOutput::ProhibitTwoArgOpen]
34+
[InputOutput::RequireCheckedOpen]
35+
[InputOutput::RequireEncodingWithUTF8Layer]
36+
[Miscellanea::ProhibitFormats]
37+
[Miscellanea::ProhibitUnrestrictedNoCritic]
38+
[Modules::ProhibitAutomaticExportation]
39+
[Modules::ProhibitConditionalUseStatements]
40+
[Modules::ProhibitEvilModules]
41+
[Modules::ProhibitExcessMainComplexity]
42+
[Modules::RequireBarewordIncludes]
43+
[Modules::RequireEndWithOne]
44+
[Modules::RequireFilenameMatchesPackage]
45+
[NamingConventions::ProhibitAmbiguousNames]
46+
[Objects::ProhibitIndirectSyntax]
47+
[RegularExpressions::ProhibitCaptureWithoutTest]
48+
[RegularExpressions::ProhibitComplexRegexes]
49+
[RegularExpressions::ProhibitUnusedCapture]
50+
[Subroutines::ProhibitBuiltinHomonyms]
51+
[Subroutines::ProhibitExcessComplexity]
52+
max_mccabe = 30
53+
[Subroutines::ProhibitExplicitReturnUndef]
54+
[Subroutines::ProhibitManyArgs]
55+
[Subroutines::ProhibitNestedSubs]
56+
[Subroutines::ProhibitReturnSort]
57+
[Subroutines::ProhibitUnusedPrivateSubroutines]
58+
[Subroutines::ProtectPrivateSubs]
59+
[TestingAndDebugging::ProhibitProlongedStrictureOverride]
60+
[TestingAndDebugging::RequireTestLabels]
61+
[TestingAndDebugging::RequireUseStrict]
62+
[TestingAndDebugging::RequireUseWarnings]
63+
[ValuesAndExpressions::ProhibitCommaSeparatedStatements]
64+
[ValuesAndExpressions::ProhibitComplexVersion]
65+
[ValuesAndExpressions::ProhibitImplicitNewlines]
66+
[ValuesAndExpressions::ProhibitLeadingZeros]
67+
[ValuesAndExpressions::ProhibitMismatchedOperators]
68+
[ValuesAndExpressions::ProhibitQuotesAsQuotelikeOperatorDelimiters]
69+
[ValuesAndExpressions::ProhibitSpecialLiteralHeredocTerminator]
70+
[ValuesAndExpressions::RequireQuotedHeredocTerminator]
71+
[Variables::ProhibitAugmentedAssignmentInDeclaration]
72+
allow_our = 1
73+
[Variables::ProhibitConditionalDeclarations]
74+
[Variables::ProhibitMatchVars]
75+
[Variables::ProhibitReusedNames]
76+
[Variables::ProhibitUnusedVariables]
77+
[Variables::ProtectPrivateVars]
78+
[Variables::RequireInitializationForLocalVars]
79+
[Variables::RequireLexicalLoopIterators]
80+
[Variables::RequireLocalizedPunctuationVars]
81+
[Variables::RequireNegativeIndices]

Changes

+32-28
Original file line numberDiff line numberDiff line change
@@ -1,59 +1,63 @@
1+
Revision history for Perl extension Catalyst-Action-RenderView
2+
3+
{{ $NEXT }}
4+
15
0.16 2011-01-05 19:28:00 GMT
2-
- Fix bug accidentally introduced in the last version with response
3-
3xx statuses.
6+
- Fix bug accidentally introduced in the last version with response
7+
3xx statuses.
48

59
0.15 2011-01-04 14:19:36 CET
6-
- Don't delegate to a view if the response body is set to `undef'.
7-
- Make sure a Test::More with done_testing support is available.
10+
- Don't delegate to a view if the response body is set to `undef'.
11+
- Make sure a Test::More with done_testing support is available.
812

913
0.14 2009-12-03 03:13:23 GMT
10-
- Remove warnings from tests about actions in the app root
14+
- Remove warnings from tests about actions in the app root
1115

1216
0.13 2009-10-24 04:48:03 PDT
13-
- Re-release 0.12 without changes for reindexing by CPAN/PAUSE.
17+
- Re-release 0.12 without changes for reindexing by CPAN/PAUSE.
1418

1519
0.12 2009-10-18 19:10:00 BST
16-
- Fixup copyright information
20+
- Fixup copyright information
1721

1822
0.11 2009-06-28 19:29:16
19-
- Update Module::Install to 0.87 to unbreak auto_install.
20-
No functional changes.
23+
- Update Module::Install to 0.87 to unbreak auto_install.
24+
No functional changes.
2125

2226
0.10 2009-04-29 18:24:50
23-
- Depend on Data::Visitor 0.24 to avoid Class::MOP deprecation
24-
warnings. (Florian Ragwitz)
27+
- Depend on Data::Visitor 0.24 to avoid Class::MOP deprecation
28+
warnings. (Florian Ragwitz)
2529

2630
0.09 2009-02-18 21:32:00
27-
- Store config in $c->config->{'Action::RenderView'}
28-
instead of $c->config->{debug}.
29-
Config from $c->config->{debug} is deprecated, but
30-
still supported.
31-
- Switch from NEXT to next::method
31+
- Store config in $c->config->{'Action::RenderView'}
32+
instead of $c->config->{debug}.
33+
Config from $c->config->{debug} is deprecated, but
34+
still supported.
35+
- Switch from NEXT to next::method
3236

3337
0.08 2008-05-02 19:40:00
34-
- Add AsCGI to list of test requirements.
35-
- Check for defined()ness of $c->res->body so "0" is valid. (RT #30564)
38+
- Add AsCGI to list of test requirements.
39+
- Check for defined()ness of $c->res->body so "0" is valid. (RT #30564)
3640

3741
0.07 2007-09-01 11:03:00
38-
- Add DateTime to default list of scrubbed objects
39-
- Stringify rather than ref by default ,
40-
more explicit message
42+
- Add DateTime to default list of scrubbed objects
43+
- Stringify rather than ref by default ,
44+
more explicit message
4145

4246
0.06 2007-08-29 16:35:00
43-
- Add support for scrubbing stash objects.
44-
- Remove undef warning
47+
- Add support for scrubbing stash objects.
48+
- Remove undef warning
4549

4650
0.05 2007-04-26
47-
- switch to Module::Install
51+
- switch to Module::Install
4852

4953
0.04 2006-07-04 09:21:00
50-
- That debug code wasn't quite production ready : /
54+
- That debug code wasn't quite production ready : /
5155

5256
0.03 2006-07-02 11:26:00
53-
- Forgot to update use test as well, silly git.
57+
- Forgot to update use test as well, silly git.
5458

5559
0.02 2006-06-29 14:59:00
56-
- Oops, moved content check ending brace up.
60+
- Oops, moved content check ending brace up.
5761

5862
0.01 2006-06-26 17:14:00
59-
- Initial release
63+
- Initial release

0 commit comments

Comments
 (0)