Skip to content

Commit 238fc88

Browse files
authored
Merge pull request #347 from gjtorikian/v3
V3 Release
2 parents 84c75b3 + 7851264 commit 238fc88

File tree

91 files changed

+2952
-3575
lines changed

Some content is hidden

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

91 files changed

+2952
-3575
lines changed

.github/FUNDING.yml

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,12 @@
1+
# These are supported funding model platforms
2+
13
github: gjtorikian
2-
patreon: gjtorikian
3-
open_collective: garen-torikian
4-
issuehunt: gjtorikian
4+
# patreon: gjtorikian
5+
# open_collective: garen-torikian
6+
#ko_fi: # Replace with a single Ko-fi username
7+
#tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
8+
#community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
9+
#liberapay: # Replace with a single Liberapay username
10+
# issuehunt: gjtorikian
11+
#otechie: # Replace with a single Otechie username
12+
#custom: # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2']

.github/dependabot.yml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
version: 2
2+
updates:
3+
- package-ecosystem: "github-actions"
4+
directory: "/"
5+
schedule:
6+
interval: daily
7+
time: "09:00"
8+
timezone: "Etc/UTC"
9+
open-pull-requests-limit: 10
10+
11+
- package-ecosystem: "bundler"
12+
directory: "/"
13+
schedule:
14+
interval: daily
15+
time: "09:00"
16+
timezone: "Etc/UTC"
17+
open-pull-requests-limit: 10
18+
allow:
19+
- dependency-name: "*"
20+
dependency-type: "production"

.github/workflows/automerge.yml

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
name: PR auto-{approve,merge}
2+
3+
on:
4+
pull_request_target:
5+
6+
permissions:
7+
pull-requests: write
8+
contents: write
9+
10+
jobs:
11+
dependabot:
12+
name: Dependabot
13+
runs-on: ubuntu-latest
14+
15+
if: ${{ github.actor == 'dependabot[bot]' }}
16+
steps:
17+
- name: Fetch Dependabot metadata
18+
id: dependabot-metadata
19+
uses: dependabot/fetch-metadata@v1
20+
with:
21+
github-token: "${{ secrets.GITHUB_TOKEN }}"
22+
23+
- name: Approve Dependabot PR
24+
if: ${{steps.dependabot-metadata.outputs.update-type != 'version-update:semver-major'}}
25+
run: gh pr review --approve "$PR_URL"
26+
env:
27+
PR_URL: ${{github.event.pull_request.html_url}}
28+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
29+
30+
- name: Merge Dependabot PR
31+
run: gh pr merge --auto --squash "$PR_URL"
32+
env:
33+
PR_URL: ${{ github.event.pull_request.html_url }}
34+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/lint.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: Linting
2+
3+
on:
4+
pull_request:
5+
paths:
6+
- "**/*.rb"
7+
8+
permissions:
9+
contents: read
10+
11+
jobs:
12+
test:
13+
runs-on: ubuntu-latest
14+
steps:
15+
- uses: actions/checkout@v3
16+
- uses: ruby/setup-ruby@v1
17+
with:
18+
ruby-version: 3.1.0
19+
rubygems: latest
20+
bundler-cache: true
21+
- run: bundle install
22+
- name: Rubocop
23+
run: bundle exec rake rubocop
Lines changed: 70 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,70 @@
1+
name: Tag and Release
2+
3+
on:
4+
workflow_dispatch:
5+
push:
6+
branches:
7+
- main
8+
paths:
9+
- "lib/html_pipeline/version.rb"
10+
11+
jobs:
12+
release:
13+
env:
14+
GEM_NAME: html-pipeline
15+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
16+
GEM_HOST_API_KEY: ${{ secrets.RUBYGEMS_API_BOT_KEY }}
17+
runs-on: ubuntu-latest
18+
steps:
19+
- uses: actions/checkout@v3
20+
21+
- name: Set up Ruby 3.1
22+
uses: ruby/setup-ruby@v1
23+
with:
24+
ruby-version: 3.1
25+
bundler-cache: true
26+
27+
- name: Configure Git
28+
run: |
29+
git config --local user.email "[email protected]"
30+
git config --local user.name "Actions Auto Build"
31+
32+
- name: Get current version
33+
id: version-label
34+
run: |
35+
VERSION=$(grep VERSION lib/html_pipeline/version.rb | head -n 1 | cut -d'"' -f2)
36+
echo "version=${VERSION}" >> $GITHUB_OUTPUT
37+
38+
- name: Create tag
39+
run: |
40+
git tag -a v${{ steps.version-label.outputs.version }} -m "Release v${{ steps.version-label.outputs.version }}"
41+
git push origin --tags
42+
43+
- name: Generate CHANGELOG.md
44+
id: changelog
45+
run: script/generate_changelog
46+
47+
- name: Commit & Push Changelog
48+
run: |
49+
git config --local user.email "[email protected]"
50+
git config --local user.name "Actions Auto Build"
51+
git add -f CHANGELOG.md
52+
git commit -m "docs: update changelog" || true
53+
git push
54+
55+
- name: Publish release
56+
env:
57+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
58+
run: |
59+
gh release create v${{ steps.version-label.outputs.version }} --generate-notes
60+
61+
- name: Publish to RubyGems
62+
run: |
63+
mkdir -p $HOME/.gem
64+
touch $HOME/.gem/credentials
65+
chmod 0600 $HOME/.gem/credentials
66+
printf -- "---\n:rubygems_api_key: ${GEM_HOST_API_KEY}\n" > $HOME/.gem/credentials
67+
bundle exec rake package
68+
for gem in pkg/html-pipeline-${{ steps.version-label.outputs.version }}*.gem ; do
69+
gem push "$gem" --host https://rubygems.org
70+
done

.github/workflows/test.yml

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
name: Tests
2+
3+
on:
4+
pull_request:
5+
6+
permissions:
7+
contents: read
8+
9+
jobs:
10+
test:
11+
runs-on: ubuntu-latest
12+
13+
strategy:
14+
fail-fast: true
15+
matrix:
16+
ruby-version:
17+
- 3.1.0
18+
19+
steps:
20+
- uses: actions/checkout@v3
21+
22+
- name: Set up Ruby ${{ matrix.ruby-version }}
23+
uses: ruby/setup-ruby@v1
24+
with:
25+
ruby-version: ${{ matrix.ruby-version }}
26+
rubygems: latest
27+
bundler-cache: true
28+
29+
- name: Install dependencies
30+
run: bundle install
31+
32+
- name: Run tests
33+
run: bundle exec rake test

.rubocop.yml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
inherit_gem:
2+
rubocop-standard:
3+
- config/default.yml
4+
- config/minitest.yml
5+
6+
inherit_mode:
7+
merge:
8+
- Exclude
9+
10+
AllCops:
11+
Exclude:
12+
- test/progit/**/*
13+
- "pkg/**/*"
14+
- "ext/**/*"
15+
- "vendor/**/*"
16+
- "tmp/**/*"
17+
- "test/progit/**/*"

.travis.yml

Lines changed: 0 additions & 43 deletions
This file was deleted.

Appraisals

Lines changed: 0 additions & 19 deletions
This file was deleted.

CHANGELOG.md

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -56,10 +56,7 @@
5656

5757
**Merged pull requests:**
5858

59-
- Replace whitelist with more neutral language [\#339](https://github.com/gjtorikian/html-pipeline/pull/339) ([tancnle](https://github.com/tancnle))
60-
- allows progress tags to be used [\#338](https://github.com/gjtorikian/html-pipeline/pull/338) ([pedrozath](https://github.com/pedrozath))
61-
- Updated English [\#337](https://github.com/gjtorikian/html-pipeline/pull/337) ([BhuvnendraPratapSingh](https://github.com/BhuvnendraPratapSingh))
62-
- Make AutolinkFilter configurable [\#335](https://github.com/gjtorikian/html-pipeline/pull/335) ([mnishiguchi](https://github.com/mnishiguchi))
59+
* Freeze all elements in HTML::Pipeline::SanitizationFilter [#299](https://github.com/jch/html-pipeline/pull/299)
6360

6461
## [v2.14.0](https://github.com/gjtorikian/html-pipeline/tree/v2.14.0) (2020-08-11)
6562

0 commit comments

Comments
 (0)