Skip to content

Commit

Permalink
Merge pull request #347 from gjtorikian/v3
Browse files Browse the repository at this point in the history
V3 Release
  • Loading branch information
gjtorikian committed Jan 26, 2023
2 parents 84c75b3 + 42da1eb commit 4750c10
Show file tree
Hide file tree
Showing 93 changed files with 3,075 additions and 3,575 deletions.
14 changes: 11 additions & 3 deletions .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,12 @@
# These are supported funding model platforms

github: gjtorikian
patreon: gjtorikian
open_collective: garen-torikian
issuehunt: gjtorikian
# patreon: gjtorikian
# open_collective: garen-torikian
#ko_fi: # Replace with a single Ko-fi username
#tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
#community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
#liberapay: # Replace with a single Liberapay username
# issuehunt: gjtorikian
#otechie: # Replace with a single Otechie username
#custom: # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2']
20 changes: 20 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
version: 2
updates:
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: daily
time: "09:00"
timezone: "Etc/UTC"
open-pull-requests-limit: 10

- package-ecosystem: "bundler"
directory: "/"
schedule:
interval: daily
time: "09:00"
timezone: "Etc/UTC"
open-pull-requests-limit: 10
allow:
- dependency-name: "*"
dependency-type: "production"
34 changes: 34 additions & 0 deletions .github/workflows/automerge.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: PR auto-{approve,merge}

on:
pull_request_target:

permissions:
pull-requests: write
contents: write

jobs:
dependabot:
name: Dependabot
runs-on: ubuntu-latest

if: ${{ github.actor == 'dependabot[bot]' }}
steps:
- name: Fetch Dependabot metadata
id: dependabot-metadata
uses: dependabot/fetch-metadata@v1
with:
github-token: "${{ secrets.GITHUB_TOKEN }}"

- name: Approve Dependabot PR
if: ${{steps.dependabot-metadata.outputs.update-type != 'version-update:semver-major'}}
run: gh pr review --approve "$PR_URL"
env:
PR_URL: ${{github.event.pull_request.html_url}}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Merge Dependabot PR
run: gh pr merge --auto --squash "$PR_URL"
env:
PR_URL: ${{ github.event.pull_request.html_url }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
23 changes: 23 additions & 0 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Linting

on:
pull_request:
paths:
- "**/*.rb"

permissions:
contents: read

jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: ruby/setup-ruby@v1
with:
ruby-version: 3.1.0
rubygems: latest
bundler-cache: true
- run: bundle install
- name: Rubocop
run: bundle exec rake rubocop
70 changes: 70 additions & 0 deletions .github/workflows/tag_and_release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
name: Tag and Release

on:
workflow_dispatch:
push:
branches:
- main
paths:
- "lib/html_pipeline/version.rb"

jobs:
release:
env:
GEM_NAME: html-pipeline
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GEM_HOST_API_KEY: ${{ secrets.RUBYGEMS_API_BOT_KEY }}
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

- name: Set up Ruby 3.1
uses: ruby/setup-ruby@v1
with:
ruby-version: 3.1
bundler-cache: true

- name: Configure Git
run: |
git config --local user.email "[email protected]"
git config --local user.name "Actions Auto Build"
- name: Get current version
id: version-label
run: |
VERSION=$(grep VERSION lib/html_pipeline/version.rb | head -n 1 | cut -d'"' -f2)
echo "version=${VERSION}" >> $GITHUB_OUTPUT
- name: Create tag
run: |
git tag -a v${{ steps.version-label.outputs.version }} -m "Release v${{ steps.version-label.outputs.version }}"
git push origin --tags
- name: Generate CHANGELOG.md
id: changelog
run: script/generate_changelog

- name: Commit & Push Changelog
run: |
git config --local user.email "[email protected]"
git config --local user.name "Actions Auto Build"
git add -f CHANGELOG.md
git commit -m "docs: update changelog" || true
git push
- name: Publish release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
gh release create v${{ steps.version-label.outputs.version }} --generate-notes
- name: Publish to RubyGems
run: |
mkdir -p $HOME/.gem
touch $HOME/.gem/credentials
chmod 0600 $HOME/.gem/credentials
printf -- "---\n:rubygems_api_key: ${GEM_HOST_API_KEY}\n" > $HOME/.gem/credentials
bundle exec rake package
for gem in pkg/html-pipeline-${{ steps.version-label.outputs.version }}*.gem ; do
gem push "$gem" --host https://rubygems.org
done
33 changes: 33 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: Tests

on:
pull_request:

permissions:
contents: read

jobs:
test:
runs-on: ubuntu-latest

strategy:
fail-fast: true
matrix:
ruby-version:
- 3.1.0

steps:
- uses: actions/checkout@v3

- name: Set up Ruby ${{ matrix.ruby-version }}
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby-version }}
rubygems: latest
bundler-cache: true

- name: Install dependencies
run: bundle install

- name: Run tests
run: bundle exec rake test
17 changes: 17 additions & 0 deletions .rubocop.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
inherit_gem:
rubocop-standard:
- config/default.yml
- config/minitest.yml

inherit_mode:
merge:
- Exclude

AllCops:
Exclude:
- test/progit/**/*
- "pkg/**/*"
- "ext/**/*"
- "vendor/**/*"
- "tmp/**/*"
- "test/progit/**/*"
43 changes: 0 additions & 43 deletions .travis.yml

This file was deleted.

19 changes: 0 additions & 19 deletions Appraisals

This file was deleted.

5 changes: 1 addition & 4 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,10 +56,7 @@

**Merged pull requests:**

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

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

Expand Down
60 changes: 0 additions & 60 deletions CONTRIBUTING.md

This file was deleted.

Loading

0 comments on commit 4750c10

Please sign in to comment.