Skip to content

Commit

Permalink
chore: fixup
Browse files Browse the repository at this point in the history
  • Loading branch information
splincode committed Jun 12, 2024
1 parent f4bb486 commit 36722a2
Show file tree
Hide file tree
Showing 13 changed files with 23,559 additions and 17,998 deletions.
31 changes: 31 additions & 0 deletions .github/workflows/announce.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: Release announce
on:
push:
branches: [main]

jobs:
run-release:
name: Announce
if: "contains(github.event.head_commit.message, 'chore(release)')"
runs-on: ubuntu-latest
steps:
- uses: taiga-family/ci/actions/setup/[email protected]
- uses: taiga-family/ci/actions/setup/[email protected]

- id: info
run: |
echo "version=v$(node -p "require('./projects/ng-event-plugins/package.json').version")" >> $GITHUB_OUTPUT
echo "name=$(node -p "require('./projects/ng-event-plugins/package.json').name")" >> $GITHUB_OUTPUT
- name: Announce to Telegram
uses: taiga-family/ci/actions/messenger/telegram/[email protected]
with:
chatId: ${{ secrets.TAIGA_TELEGRAM_CHAT_ID }}
topicId: ${{ secrets.TAIGA_TELEGRAM_CHAT_THREAD_ID }}
token: ${{ secrets.TAIGA_TELEGRAM_BOT_TOKEN }}
version: ${{ steps.info.outputs.version }}
textLink: ${{ steps.info.outputs.name }}

concurrency:
group: announce-${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
12 changes: 0 additions & 12 deletions .github/workflows/auto-add-to-project.yml

This file was deleted.

23 changes: 0 additions & 23 deletions .github/workflows/auto-cleanup-caches.yml

This file was deleted.

12 changes: 0 additions & 12 deletions .github/workflows/auto-dependency-review.yml

This file was deleted.

57 changes: 57 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
name: ⚠️ Release
on:
workflow_dispatch:
inputs:
forcePush:
type: boolean
required: false
description: --force-publish package
mode:
type: choice
description: force package to be versioned (depend --force-publish)
required: false
default: minor
options:
- patch
- minor
- major
- prepatch

jobs:
run-release:
name: Run release
runs-on: ubuntu-latest
if: "!contains(github.event.head_commit.message, 'chore(release)')"
env:
GITHUB_TOKEN: ${{ secrets.TAIGA_FAMILY_BOT_PAT }}
steps:
- uses: taiga-family/ci/actions/setup/[email protected]
with:
token: ${{ secrets.TAIGA_FAMILY_BOT_PAT }}
ref: ${{ github.ref }}
fetch-depth: 0
- uses: taiga-family/ci/actions/setup/[email protected]
- uses: taiga-family/ci/actions/setup/[email protected]
- uses: taiga-family/ci/actions/setup/config/[email protected]
with:
token: ${{ secrets.TAIGA_FAMILY_BOT_PAT }}
- uses: taiga-family/ci/actions/setup/config/[email protected]
with:
token: ${{ secrets.TAIGA_UI_SCOPE_NPM_TOKEN }}

- run: |
if [[ "${{ github.event.inputs.forcePush }}" == "true" ]]; then
if [[ "${{ github.event.inputs.mode }}" != "prepatch" ]]; then
npx release-it "${{ github.event.inputs.mode }}" --increment --ci
else
npx release-it --preRelease=alpha --ci
fi
else
npx release-it --increment --ci
fi
concurrency:
group: release-${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
29 changes: 29 additions & 0 deletions .release-it.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
{
"git": {
"commitMessage": "chore(release): v${version}",
"tagName": "v${version}"
},
"github": {
"release": true,
"releaseNotes": "git log --no-merges --pretty=format:\"* %s %h\" ${latestTag}...main"
},
"npm": {
"publish": false,
"skipChecks": true,
"allowSameVersion": true
},
"plugins": {
"@release-it-plugins/workspaces": {
"skipChecks": true,
"publish": false
},
"@release-it/conventional-changelog": {
"preset": "angular",
"infile": "CHANGELOG.md"
}
},
"hooks": {
"after:bump": "npx nx build ng-dompurify && npx nx publish ng-dompurify",
"after:release": "echo Successfully released ${name} v${version} to ${repo.repository}."
}
}
94 changes: 0 additions & 94 deletions angular.json

This file was deleted.

43 changes: 43 additions & 0 deletions nx.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
{
"affected": {
"defaultBase": "main"
},
"tasksRunnerOptions": {
"default": {
"options": {
"canTrackAnalytics": false,
"showUsageWarnings": true
}
}
},
"$schema": "./node_modules/nx/schemas/nx-schema.json",
"targetDefaults": {
"build": {
"dependsOn": ["^build"],
"inputs": ["production", "^production"],
"cache": true
},
"test": {
"inputs": ["default", "^production", "{workspaceRoot}/jest.preset.js"],
"cache": true
},
"lint": {
"cache": true
}
},
"namedInputs": {
"default": ["{projectRoot}/**/*", "sharedGlobals"],
"sharedGlobals": [
"{workspaceRoot}/angular.json",
"{workspaceRoot}/tsconfig.json",
"{workspaceRoot}/tslint.json",
"{workspaceRoot}/nx.json"
],
"production": [
"default",
"!{projectRoot}/**/?(*.)+(spec|test).[jt]s?(x)?(.snap)",
"!{projectRoot}/tsconfig.spec.json",
"!{projectRoot}/jest.config.[jt]s"
]
}
}
Loading

0 comments on commit 36722a2

Please sign in to comment.