Skip to content

Commit 72b473f

Browse files
authored
chore: Add IGNORE_APP_RELATIONSHIP ENV
2 parents de5b231 + 56f3250 commit 72b473f

4 files changed

Lines changed: 34 additions & 11 deletions

File tree

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,11 @@ All notable changes to this project will be documented in this file.
55
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
66
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
77

8+
## [0.19.0] - 2026-04-20
9+
10+
### Added
11+
- `IGNORE_APP_RELATIONSHIP` env var. When set, the `app` field in target configs is ignored — targets are no longer triggered just because their corresponding app is tainted (only direct changes, lockfile changes, and tainted workspace imports apply).
12+
813
## [0.18.1] - 2026-04-13
914

1015
### Changed
@@ -257,6 +262,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
257262
- Multi-stage Docker build
258263
- Automated vendor upgrade workflow
259264

265+
[0.19.0]: https://github.com/gooddata/gooddata-goodchanges/compare/v0.18.1...v0.19.0
260266
[0.18.1]: https://github.com/gooddata/gooddata-goodchanges/compare/v0.18.0...v0.18.1
261267
[0.18.0]: https://github.com/gooddata/gooddata-goodchanges/compare/v0.17.1...v0.18.0
262268
[0.17.1]: https://github.com/gooddata/gooddata-goodchanges/compare/v0.17.0...v0.17.1

README.md

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -57,14 +57,15 @@ JSON array of target objects:
5757

5858
## Environment variables
5959

60-
| Variable | Description | Default |
61-
|------------------|-------------------------------------------------------------------------------------------------------------------------------|-----------------|
62-
| `LOG_LEVEL` | Logging verbosity. `BASIC` for standard logging, `DEBUG` for verbose AST/taint tracing to stderr | _(no logging)_ |
63-
| `INCLUDE_TYPES` | When set to any non-empty value, includes type-only changes (interfaces, type aliases, type annotations) in taint propagation | _(disabled)_ |
64-
| `INCLUDE_CSS` | When set to any non-empty value, enables CSS/SCSS change detection and taint propagation through `@use`/`@import` chains | _(disabled)_ |
65-
| `COMPARE_COMMIT` | Specific git commit hash to compare against (overrides branch-based comparison) | _(empty)_ |
66-
| `COMPARE_BRANCH` | Git branch to compute merge base against | `origin/master` |
67-
| `TARGETS` | Comma-delimited list of target names to include in output. Supports `*` wildcard (e.g. `*backstop*,@gooddata/sdk-*`). | _(all targets)_ |
60+
| Variable | Description | Default |
61+
|---------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------|-----------------|
62+
| `LOG_LEVEL` | Logging verbosity. `BASIC` for standard logging, `DEBUG` for verbose AST/taint tracing to stderr | _(no logging)_ |
63+
| `INCLUDE_TYPES` | When set to any non-empty value, includes type-only changes (interfaces, type aliases, type annotations) in taint propagation | _(disabled)_ |
64+
| `INCLUDE_CSS` | When set to any non-empty value, enables CSS/SCSS change detection and taint propagation through `@use`/`@import` chains | _(disabled)_ |
65+
| `COMPARE_COMMIT` | Specific git commit hash to compare against (overrides branch-based comparison) | _(empty)_ |
66+
| `COMPARE_BRANCH` | Git branch to compute merge base against | `origin/master` |
67+
| `TARGETS` | Comma-delimited list of target names to include in output. Supports `*` wildcard (e.g. `*backstop*,@gooddata/sdk-*`). | _(all targets)_ |
68+
| `IGNORE_APP_RELATIONSHIP` | When set to any non-empty value, ignores the `app` field in target configs. Targets are no longer triggered solely because their corresponding app is tainted. | _(disabled)_ |
6869

6970
## Library vs app detection
7071

@@ -124,7 +125,7 @@ Each target is triggered by any of these conditions:
124125
1. **Direct file changes** -- files matching `changeDirs` globs changed (excluding ignored paths). Defaults to `**/*` (entire project) when `changeDirs` is not set.
125126
2. **External dependency changes** -- a dependency version changed in `pnpm-lock.yaml`
126127
3. **Tainted workspace imports** -- a file matching `changeDirs` globs imports a tainted symbol from a workspace library
127-
4. **Corresponding app is tainted** -- the app specified by `app` is affected (any of the above conditions)
128+
4. **Corresponding app is tainted** -- the app specified by `app` is affected (any of the above conditions). Disabled when `IGNORE_APP_RELATIONSHIP` env var is set.
128129

129130
### changeDirs
130131

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
0.18.1
1+
0.19.0

main.go

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ var version string
2424

2525
var flagIncludeTypes bool
2626
var flagIncludeCSS bool
27+
var flagIgnoreAppRelationship bool
2728
var flagLog bool
2829
var flagDebug bool
2930

@@ -51,10 +52,25 @@ func main() {
5152
fmt.Println()
5253
os.Exit(0)
5354
}
55+
if arg == "--list" {
56+
rushConfig, err := rush.LoadConfig(".")
57+
if err != nil {
58+
fmt.Fprintf(os.Stderr, "Error loading rush config: %v\n", err)
59+
os.Exit(1)
60+
}
61+
data, err := json.MarshalIndent(rushConfig.Projects, "", " ")
62+
if err != nil {
63+
fmt.Fprintf(os.Stderr, "Error marshalling projects: %v\n", err)
64+
os.Exit(1)
65+
}
66+
fmt.Println(string(data))
67+
os.Exit(0)
68+
}
5469
}
5570

5671
flagIncludeTypes = envBool("INCLUDE_TYPES")
5772
flagIncludeCSS = envBool("INCLUDE_CSS")
73+
flagIgnoreAppRelationship = envBool("IGNORE_APP_RELATIONSHIP")
5874

5975
logLevel := strings.ToUpper(os.Getenv("LOG_LEVEL"))
6076
flagLog = logLevel == "BASIC" || logLevel == "DEBUG"
@@ -392,7 +408,7 @@ func main() {
392408
}
393409

394410
// Quick check: app taint
395-
if td.App != nil {
411+
if td.App != nil && !flagIgnoreAppRelationship {
396412
appInfo := projectMap[*td.App]
397413
if appInfo != nil {
398414
if changedProjects[*td.App] != nil {

0 commit comments

Comments
 (0)