Skip to content

Commit

Permalink
Update AGTree to v1.1.8, update workflows
Browse files Browse the repository at this point in the history
Merge in ADGUARD-FILTERS/aglint from update-agtree-to-v1.1.8 to master

Squashed commit of the following:

commit d5619e7
Author: scripthunter7 <[email protected]>
Date:   Thu Apr 25 10:33:17 2024 +0200

    fix job name

commit ec541fe
Author: scripthunter7 <[email protected]>
Date:   Wed Apr 24 19:44:11 2024 +0200

    categorize link definitions

commit 5857019
Author: scripthunter7 <[email protected]>
Date:   Wed Apr 24 18:27:57 2024 +0200

    fix comment

commit 440c1fd
Author: scripthunter7 <[email protected]>
Date:   Wed Apr 24 18:23:40 2024 +0200

    add jest types

commit 99ea0aa
Author: scripthunter7 <[email protected]>
Date:   Wed Apr 24 18:20:49 2024 +0200

    update gh workflows

commit ed8f879
Author: scripthunter7 <[email protected]>
Date:   Wed Apr 24 17:59:22 2024 +0200

    fix error message matching

commit 960531e
Author: scripthunter7 <[email protected]>
Date:   Wed Apr 24 17:54:04 2024 +0200

    changelog

commit 211cc2c
Author: scripthunter7 <[email protected]>
Date:   Wed Apr 24 17:53:48 2024 +0200

    update agtree to v1.1.8

commit 0e5b994
Author: scripthunter7 <[email protected]>
Date:   Wed Apr 24 17:53:05 2024 +0200

    remove redundant dev docs

commit 9b04d87
Author: scripthunter7 <[email protected]>
Date:   Wed Apr 24 17:52:51 2024 +0200

    update, format bamboo specs files

commit 672741b
Author: scripthunter7 <[email protected]>
Date:   Wed Apr 24 17:52:12 2024 +0200

    update github workflows
  • Loading branch information
scripthunter7 committed Apr 25, 2024
1 parent fa55868 commit f255c01
Show file tree
Hide file tree
Showing 12 changed files with 207 additions and 90 deletions.
27 changes: 14 additions & 13 deletions .github/workflows/check.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: Check code

env:
NODE_VERSION: 18
NODE_VERSION: 20

on:
push:
Expand All @@ -19,10 +19,10 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Check out to repository
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Set up Node.js
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: ${{ env.NODE_VERSION }}
cache: yarn
Expand All @@ -43,12 +43,15 @@ jobs:
run: yarn test

notify:
name: Send Slack notification
needs:
- check_code

name: Send Slack notification on failure
needs: check_code
# Run this job only if the previous job failed and the event was triggered by the 'AdguardTeam/AGLint' repository
# Note: 'always()' is needed to run the notify job even if the test job was failed
if:
${{ always() &&
${{
always() &&
needs.check_code.result == 'failure' &&
github.repository == 'AdguardTeam/AGLint' &&
(
github.event_name == 'push' ||
github.event_name == 'workflow_dispatch' ||
Expand All @@ -57,14 +60,12 @@ jobs:
}}
runs-on: ubuntu-latest
steps:
- name: Conclusion
uses: technote-space/workflow-conclusion-action@v3

- name: Send Slack notification
uses: 8398a7/action-slack@v3
with:
status: ${{ env.WORKFLOW_CONCLUSION }}
fields: workflow, repo, message, commit, author, eventName, ref
status: failure
fields: workflow, repo, message, commit, author, eventName, ref, job
job_name: check_code
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
29 changes: 13 additions & 16 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: Create GitHub Release

env:
NODE_VERSION: 18
NODE_VERSION: 20

on:
push:
Expand All @@ -22,10 +22,10 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Check out the repository
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Set up Node.js
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: ${{ env.NODE_VERSION }}
registry-url: https://registry.npmjs.org
Expand Down Expand Up @@ -61,32 +61,29 @@ jobs:
dist/aglint.umd.min.js
draft: false
prerelease: false
# TODO: Extract data from CHANGELOG.md
body: See [CHANGELOG.md](./CHANGELOG.md) for the list of changes.
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

notify:
name: Send Slack notification
needs:
- release

needs: release
# Note: 'always()' is needed to run the notify job even if the test job was failed
if:
${{ always() &&
(
github.event_name == 'push' ||
github.event_name == 'workflow_dispatch'
)
${{
always() &&
github.repository == 'AdguardTeam/AGLint' &&
github.event_name == 'push'
}}
runs-on: ubuntu-latest
steps:
- name: Conclusion
uses: technote-space/workflow-conclusion-action@v3

- name: Send Slack notification
uses: 8398a7/action-slack@v3
with:
status: ${{ env.WORKFLOW_CONCLUSION }}
fields: workflow, repo, message, commit, author, eventName, ref
status: ${{ needs.release.result }}
fields: workflow, repo, message, commit, author, eventName, ref, job
job_name: release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
70 changes: 47 additions & 23 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,16 +1,36 @@
<!-- markdownlint-disable MD024 -->
# AGLint Changelog

All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog][keepachangelog], and this project adheres to [Semantic Versioning][semver].

[keepachangelog]: https://keepachangelog.com/en/1.0.0/
[semver]: https://semver.org/spec/v2.0.0.html

## [2.0.9] - 2024-04-25

### Fixed

- Validation for `$permissions` modifier [#206].

### Changed

- Updated [@adguard/agtree] to `v1.1.8`.

[#206]: https://github.com/AdguardTeam/AGLint/issues/206
[2.0.9]: https://github.com/AdguardTeam/AGLint/compare/v2.0.8...v2.0.9


## [2.0.8] - 2024-01-09

### Fixed

- Absolute paths in the CLI [#184].

[#184]: https://github.com/AdguardTeam/AGLint/issues/184
[2.0.8]: https://github.com/AdguardTeam/AGLint/compare/v2.0.6...v2.0.8


## [2.0.6] - 2023-11-07

Expand All @@ -22,13 +42,18 @@ The format is based on [Keep a Changelog][keepachangelog], and this project adhe

- Updated [@adguard/agtree] to `v1.1.7`.

[#185]: https://github.com/AdguardTeam/AGLint/issues/185
[2.0.6]: https://github.com/AdguardTeam/AGLint/compare/v2.0.5...v2.0.6


## [2.0.5] - 2023-09-07

### Changed

- Updated [@adguard/agtree] to `v1.1.5`.

[2.0.5]: https://github.com/AdguardTeam/AGLint/compare/v2.0.4...v2.0.5


## [2.0.4] - 2023-08-30

Expand All @@ -37,6 +62,8 @@ The format is based on [Keep a Changelog][keepachangelog], and this project adhe
- Override `config.extends`'s presets by the user config.
- Updated [@adguard/agtree] to `v1.1.4`.

[2.0.4]: https://github.com/AdguardTeam/AGLint/compare/v2.0.3...v2.0.4


## [2.0.3] - 2023-08-29

Expand All @@ -50,6 +77,8 @@ The format is based on [Keep a Changelog][keepachangelog], and this project adhe

- Updated [@adguard/agtree] to `v1.1.3`.

[2.0.3]: https://github.com/AdguardTeam/AGLint/compare/v2.0.1...v2.0.3


## [2.0.1] - 2023-08-14

Expand All @@ -58,6 +87,8 @@ The format is based on [Keep a Changelog][keepachangelog], and this project adhe
- Make `syntax` property in the config required.
- Updated [@adguard/agtree] to `v1.1.2`.

[2.0.1]: https://github.com/AdguardTeam/AGLint/compare/v2.0.0...v2.0.1


## [2.0.0] - 2023-08-11

Expand All @@ -70,6 +101,8 @@ The format is based on [Keep a Changelog][keepachangelog], and this project adhe

- Updated [@adguard/agtree] to `v1.1.1`.

[2.0.0]: https://github.com/AdguardTeam/AGLint/compare/v1.0.11...v2.0.0


## [1.0.11] - 2023-04-21

Expand All @@ -84,6 +117,8 @@ The format is based on [Keep a Changelog][keepachangelog], and this project adhe
- Config files are now required to run the linter.
- Locations are handled in linter rules.

[1.0.11]: https://github.com/AdguardTeam/AGLint/compare/v1.0.10...v1.0.11


## [1.0.10] - 2023-03-30

Expand All @@ -104,6 +139,9 @@ The format is based on [Keep a Changelog][keepachangelog], and this project adhe

- Temporary removed `adg-scriptlet-quotes` linter rule.

[#10]: https://github.com/AdguardTeam/AGLint/issues/10
[1.0.10]: https://github.com/AdguardTeam/AGLint/compare/v1.0.9...v1.0.10


## [1.0.9] - 2023-03-02

Expand All @@ -127,6 +165,8 @@ The format is based on [Keep a Changelog][keepachangelog], and this project adhe

- Network rule separator finder sometimes found the wrong separator.

[1.0.9]: https://github.com/AdguardTeam/AGLint/compare/v1.0.8...v1.0.9


## [1.0.8] - 2023-02-13

Expand All @@ -135,13 +175,20 @@ The format is based on [Keep a Changelog][keepachangelog], and this project adhe
- Improved console reporter, shows linter rule name when reporting problems.
- Detailed error messages when CSS parsing fails.

[1.0.8]: https://github.com/AdguardTeam/AGLint/compare/v1.0.7...v1.0.8


## [1.0.7] - 2023-02-10

### Fixed

- CLI exit code is now 1 if there are any linter errors.

<!-- v1.0.6 is the "oldest" tag -->
<!-- that's why the list of links starts with [1.0.7] -->
<!-- i.e. it is impossible to create compare url for 1.0.5 and 1.0.6 -->
[1.0.7]: https://github.com/AdguardTeam/AGLint/compare/v1.0.6...v1.0.7


## 1.0.6 - 2023-02-06

Expand All @@ -157,27 +204,4 @@ The format is based on [Keep a Changelog][keepachangelog], and this project adhe
- Initial version of the linter and CLI.
- Initial version of the adblock rule parser.


[2.0.8]: https://github.com/AdguardTeam/AGLint/compare/v2.0.6...v2.0.8
[2.0.6]: https://github.com/AdguardTeam/AGLint/compare/v2.0.5...v2.0.6
[2.0.5]: https://github.com/AdguardTeam/AGLint/compare/v2.0.4...v2.0.5
[2.0.4]: https://github.com/AdguardTeam/AGLint/compare/v2.0.3...v2.0.4
[2.0.3]: https://github.com/AdguardTeam/AGLint/compare/v2.0.1...v2.0.3
[2.0.1]: https://github.com/AdguardTeam/AGLint/compare/v2.0.0...v2.0.1
[2.0.0]: https://github.com/AdguardTeam/AGLint/compare/v1.0.11...v2.0.0
[1.0.11]: https://github.com/AdguardTeam/AGLint/compare/v1.0.10...v1.0.11
[1.0.10]: https://github.com/AdguardTeam/AGLint/compare/v1.0.9...v1.0.10
[1.0.9]: https://github.com/AdguardTeam/AGLint/compare/v1.0.8...v1.0.9
[1.0.8]: https://github.com/AdguardTeam/AGLint/compare/v1.0.7...v1.0.8
[1.0.7]: https://github.com/AdguardTeam/AGLint/compare/v1.0.6...v1.0.7
<!-- v1.0.6 is the "oldest" tag -->
<!-- that's why the list of links starts with [1.0.7] -->
<!-- i.e. it is impossible to create compare url for 1.0.5 and 1.0.6 -->

[keepachangelog]: https://keepachangelog.com/en/1.0.0/
[semver]: https://semver.org/spec/v2.0.0.html
[@adguard/agtree]: https://github.com/AdguardTeam/tsurlfilter/blob/master/packages/agtree/CHANGELOG.md

[#10]: https://github.com/AdguardTeam/AGLint/issues/10
[#184]: https://github.com/AdguardTeam/AGLint/issues/184
[#185]: https://github.com/AdguardTeam/AGLint/issues/185
4 changes: 0 additions & 4 deletions bamboo-specs/bamboo.yaml
Original file line number Diff line number Diff line change
@@ -1,14 +1,10 @@
---
!include 'test.yaml'

---
!include 'increment.yaml'

---
!include 'build.yaml'

---
!include 'deploy.yaml'

---
!include 'permissions.yaml'
4 changes: 2 additions & 2 deletions bamboo-specs/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ plan:
key: AGLINTBUILD
name: aglint - build release
variables:
dockerNode: adguard/node-ssh:18.13--1
dockerNode: adguard/node-ssh:21.7--1

stages:
- Build:
Expand All @@ -21,7 +21,7 @@ Build:
docker:
image: ${bamboo.dockerNode}
volumes:
${system.YARN_DIR}: "${bamboo.cacheYarn}"
${system.YARN_DIR}: '${bamboo.cacheYarn}'
tasks:
- checkout:
force-clean-build: true
Expand Down
4 changes: 2 additions & 2 deletions bamboo-specs/deploy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@ environments:

npmjs:
docker:
image: adguard/node-ssh:18.13--1
image: adguard/node-ssh:21.7--1
volumes:
${system.YARN_DIR}: "${bamboo.cacheYarn}"
${system.YARN_DIR}: '${bamboo.cacheYarn}'
triggers: []
tasks:
- checkout:
Expand Down
6 changes: 3 additions & 3 deletions bamboo-specs/increment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ plan:
key: AGLINTINCR
name: aglint - increment
variables:
dockerNode: adguard/node-ssh:18.13--1
dockerNode: adguard/node-ssh:21.7--1

stages:
- Increment:
Expand All @@ -17,9 +17,9 @@ stages:
Increment:
key: INCR
docker:
image: "${bamboo.dockerNode}"
image: '${bamboo.dockerNode}'
volumes:
${system.YARN_DIR}: "${bamboo.cacheYarn}"
${system.YARN_DIR}: '${bamboo.cacheYarn}'
other:
clean-working-dir: true
tasks:
Expand Down
6 changes: 3 additions & 3 deletions bamboo-specs/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ plan:
key: AGLINTTEST
name: aglint - tests
variables:
dockerNode: adguard/node-ssh:18.13--1
dockerNode: adguard/node-ssh:21.7--1

stages:
- Build:
Expand All @@ -17,9 +17,9 @@ stages:
Build:
key: BUILD
docker:
image: "${bamboo.dockerNode}"
image: '${bamboo.dockerNode}'
volumes:
${system.YARN_DIR}: "${bamboo.cacheYarn}"
${system.YARN_DIR}: '${bamboo.cacheYarn}'
tasks:
- checkout:
force-clean-build: true
Expand Down
Loading

0 comments on commit f255c01

Please sign in to comment.