Skip to content

Commit

Permalink
add automatic update icons & release
Browse files Browse the repository at this point in the history
  • Loading branch information
ublabs[bot] committed Sep 15, 2021
1 parent 933dd1b commit 7fa3905
Show file tree
Hide file tree
Showing 3 changed files with 92 additions and 0 deletions.
40 changes: 40 additions & 0 deletions .github/workflows/create-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: Create Release

on:
push:
branches:
- feature/update-icons

jobs:
create-release:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v2
with:
fetch-depth: 0
token: ${{ secrets.TOKEN_BOT }}
persist-credentials: false
ref: ${{ github.head_ref }}

- name: Bump version and push tag
id: tag_version
uses: mathieudutour/[email protected]
with:
tag_prefix: ""
release_branches: "feature/update-icons"
github_token: ${{ secrets.GITHUB_TOKEN }}

- name: Create a GitHub release
uses: ncipollo/release-action@v1
with:
tag: ${{ steps.tag_version.outputs.new_tag }}
name: Release ${{ steps.tag_version.outputs.new_tag }}
body: ${{ steps.tag_version.outputs.changelog }}

- name: Update Main
uses: ad-m/github-push-action@master
with:
github_token: ${{ secrets.TOKEN_BOT }}
branch: "main"
2 changes: 2 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ name: Tests

on:
push:
branches-ignore:
- feature/update-icons
pull_request:
schedule:
- cron: '0 0 * * *'
Expand Down
50 changes: 50 additions & 0 deletions .github/workflows/update-icons.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
name: Update Icons

on:
workflow_dispatch:
schedule:
- cron: 0 14 * * 0


jobs:
update-submodules:
runs-on: ubuntu-latest

strategy:
fail-fast: true
matrix:
php: [8.0]
laravel: [^8.0]

name: PHP ${{ matrix.php }} - Laravel ${{ matrix.laravel }}

steps:
- name: Checkout code
uses: actions/checkout@v2
with:
token: ${{ secrets.TOKEN_BOT }}
persist-credentials: false
fetch-depth: 0

- name: Update submodule
uses: actions/checkout@v2
with:
repository: simple-icons/simple-icons
ref: 'master'
path: ./dist

- name: Install dependencies
run: composer update --no-interaction --no-progress --dev

- name: Generate icons
run: composer run generate-icons

- name: Create commit
run: git add .

- name: Push changes
uses: actions-js/push@master
with:
github_token: ${{ secrets.TOKEN_BOT }}
branch: feature/update-icons
message: "feat(svg): update simple icons"

0 comments on commit 7fa3905

Please sign in to comment.